[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/subed a7b25c8 341/389: subed-vtt: Fix ID->timestamp and st
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/subed a7b25c8 341/389: subed-vtt: Fix ID->timestamp and stop generating IDs |
Date: |
Fri, 3 Dec 2021 11:00:54 -0500 (EST) |
branch: elpa/subed
commit a7b25c8f794918d167b027c712ad5e0a6376e3b4
Author: Sacha Chua <sacha@sachachua.com>
Commit: Random User <rndusr@posteo.de>
subed-vtt: Fix ID->timestamp and stop generating IDs
---
subed/subed-vtt.el | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/subed/subed-vtt.el b/subed/subed-vtt.el
index 574501d..baddfb3 100644
--- a/subed/subed-vtt.el
+++ b/subed/subed-vtt.el
@@ -148,14 +148,14 @@ If SUB-ID is not given, use subtitle on point."
"Move to the ID of a subtitle and return point.
If SUB-ID is not given, focus the current subtitle's ID.
Return point or nil if no subtitle ID could be found.
-WebVTT doesn't use IDs, so we use the starting timestamp instead"
+WebVTT doesn't use IDs, so we use the starting timestamp instead."
(interactive)
(save-match-data
- (if sub-id
+ (if (stringp sub-id)
;; Look for a line that contains only the ID, preceded by one or more
;; blank lines or the beginning of the buffer.
(let* ((orig-point (point))
- (regex (concat "\\(" subed-srt--regexp-separator "\\|\\`\\)\\("
(regexp-quote (string-to-number sub-id)) "\\)"))
+ (regex (concat "\\(" subed-srt--regexp-separator "\\|\\`\\)\\("
(regexp-quote sub-id) "\\)"))
(match-found (progn (goto-char (point-min))
(re-search-forward regex nil t))))
(if match-found
@@ -414,8 +414,7 @@ Return new point."
(subed-vtt--backward-subtitle-end)
(1+ (point)))
end (save-excursion (goto-char (point-max)))))
- (delete-region beg end))
- (subed-vtt--regenerate-ids-soon))
+ (delete-region beg end)))
;;; Maintenance
@@ -517,8 +516,7 @@ Return new point."
;; endrecfun (move to end of current record/subtitle)
#'subed-vtt--jump-to-subtitle-end
;; startkeyfun (return sort value of current record/subtitle)
- #'subed-vtt--subtitle-msecs-start))
- (subed-vtt--regenerate-ids)))
+ #'subed-vtt--subtitle-msecs-start))))
(defun subed-vtt--init ()
"This function is called when subed-mode is entered for a SRT file."
- [nongnu] elpa/subed b0a4ff0 307/389: Fix parentheses, (continued)
- [nongnu] elpa/subed b0a4ff0 307/389: Fix parentheses, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 8007c12 308/389: Make debugging window a bit smaller, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed ec38a0b 317/389: Add function: subed-mpv-add-subtitles, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 7764909 324/389: Add some (require ...)s to prevent compiler warnings, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed a084f5d 326/389: Improve comment, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed cd3af86 328/389: Silence checkdoc, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 29d8b84 337/389: Initial implementation of subed-vtt.el, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 6db0005 338/389: New function subed-mpv-play-video-from-url, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed d3df6f2 347/389: Fix "test" target in Makefile, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 5b8c23a 348/389: New commands: subed-merge-with-next, subed-merge-with-previous, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed a7b25c8 341/389: subed-vtt: Fix ID->timestamp and stop generating IDs,
ELPA Syncer <=
- [nongnu] elpa/subed 9796a77 349/389: Merge branch 'sacha', ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed c4e3fec 352/389: Add error handling for subed-split-subtitle, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 918ba6f 370/389: Prevent showing the "Match data clobbered" message, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 808ef92 118/389: Fix comment, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 97bb125 183/389: Add default keybindings for copying player position, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 7665826 248/389: Add tests for copying player position to start/stop time, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed a280e89 251/389: Add more text to README, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 311f4af 331/389: Require Emacs 25.1, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed fc7a12d 335/389: Fix mpv arguments, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed d9c41ba 345/389: Add test for validation fix, ELPA Syncer, 2021/12/03