[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/annotate a59cc2c6b2 172/372: - when 'delete' button from a
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/annotate a59cc2c6b2 172/372: - when 'delete' button from a summary window is activated redraw and |
Date: |
Fri, 4 Feb 2022 16:58:56 -0500 (EST) |
branch: elpa/annotate
commit a59cc2c6b2ec0311799311969e0c4122a82f4636
Author: cage <cage-invalid@invalid>
Commit: cage <cage-invalid@invalid>
- when 'delete' button from a summary window is activated redraw and
update a window that is displayng the file that contains the deleted
annotation (if such buffer exists).
---
annotate.el | 31 +++++++++++++++++++++----------
1 file changed, 21 insertions(+), 10 deletions(-)
diff --git a/annotate.el b/annotate.el
index 29af2cb00a..ee3255a47f 100644
--- a/annotate.el
+++ b/annotate.el
@@ -1511,16 +1511,27 @@ sophisticated way than plain text"
(end-of-button (button-get button 'end-of-button))
(db (annotate-load-annotation-data))
(filtered (annotate-db-remove-annotation db filename beginning
ending)))
- (annotate-dump-annotation-data filtered)
- (with-current-buffer annotate-summary-buffer-name
- (read-only-mode -1)
- (save-excursion
- (button-put button 'invisible t)
- (let ((annotation-button (previous-button (point))))
- (button-put annotation-button 'face '(:strike-through t)))
- (let ((replace-button (next-button (point))))
- (button-put replace-button 'invisible t)))
- (read-only-mode 1))))
+ (annotate-dump-annotation-data filtered) ; save the new database with
entry removed
+ (cl-labels ((redraw-summary-window () ; update the summary window
+ (with-current-buffer annotate-summary-buffer-name
+ (read-only-mode -1)
+ (save-excursion
+ (button-put button 'invisible t)
+ (let ((annotation-button (previous-button (point))))
+ (button-put annotation-button 'face '(:strike-through
t)))
+ (let ((replace-button (next-button (point))))
+ (button-put replace-button 'invisible t)))
+ (read-only-mode 1)))
+ ;; if the file where the deleted annotation belong to is
visited,
+ ;; update the buffer
+ (update-visited-buffer-maybe ()
+ (let ((visited-buffer (find-buffer-visiting filename)))
+ (when visited-buffer ;; a buffer is visiting the file
+ (with-current-buffer visited-buffer
+ (annotate-mode -1)
+ (annotate-mode 1))))))
+ (redraw-summary-window)
+ (update-visited-buffer-maybe))))
(defun annotate-summary-replace-annotation-button-pressed (button)
(let* ((filename (button-get button 'file))
- [nongnu] elpa/annotate 55e318b172 124/372: - fixed reference to a non-existent variable in the procedure that, (continued)
- [nongnu] elpa/annotate 55e318b172 124/372: - fixed reference to a non-existent variable in the procedure that, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 08f520f09a 119/372: - try to elaborate more a function goal., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 354653496d 115/372: - added a bit of (very simple) heuristic to place annotation in the, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate a1be01d886 134/372: - try to guess the actual file name of an info document when showing, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 16e0346481 128/372: - prevent showing of summary window if metadata contains no annotations at all., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 6ceeb44774 133/372: - removed check for buffer file name in funcion called just before a, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate db9e064342 132/372: - added features: annotate info documents., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4bcecdc875 156/372: - replaced 'splitted-annotation' with 'multiline-annotation'., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4fde80fe79 168/372: - updated software version number in the comment on top of the source code;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 696f4ee0cd 167/372: Merge pull request #55 from cage2/update-doc, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate a59cc2c6b2 172/372: - when 'delete' button from a summary window is activated redraw and,
ELPA Syncer <=
- [nongnu] elpa/annotate 412053cefc 173/372: - [bugfix] When a window is resized ensure that the sizes are, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 41e85c8435 176/372: - increased version number;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate cc4292cce4 181/372: - moved the test for 'limit' up in the lambda of the filtering, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate f4cc83ec84 189/372: Merge branch 'master' into org-mode-fix, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate bcffdb9f24 202/372: - added some missing docstrings., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 99c45f553e 225/372: Merge pull request #67 from cage2/new-stable-version, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate d4b555d237 242/372: Merge pull request #76 from cage2/master, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate a04a6144aa 240/372: Merge pull request #75 from cage2/master, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate a4607c4184 273/372: - updated version and documentation., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate daf4c3c726 283/372: - removed code, in integration procedures, that should never runs., ELPA Syncer, 2022/02/04