emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/org-remark 75d8fd3c9d 19/37: refactor(mark): save notes


From: ELPA Syncer
Subject: [elpa] externals/org-remark 75d8fd3c9d 19/37: refactor(mark): save notes buf only when create/change
Date: Sat, 14 Jan 2023 10:58:01 -0500 (EST)

branch: externals/org-remark
commit 75d8fd3c9d653873aa0a45870e123f7889459d91
Author: Noboru Ota <me@nobiot.com>
Commit: Noboru Ota <me@nobiot.com>

    refactor(mark): save notes buf only when create/change
---
 org-remark.el | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/org-remark.el b/org-remark.el
index 2802a18d70..f5ab1718be 100644
--- a/org-remark.el
+++ b/org-remark.el
@@ -762,15 +762,15 @@ round-trip back to the notes file."
            (unless (overlay-get ov 'help-echo)
              (overlay-put ov 'help-echo (plist-get notes-props :body)))
            (overlay-put ov '*org-remark-note-body
-                        (plist-get notes-props :body)))))
+                        (plist-get notes-props :body)))
+         ;; Save the notes buffer when not loading
+         (let ((notes-buf (find-file-noselect 
(org-remark-notes-get-file-name))))
+           (unless (eq notes-buf (current-buffer))
+             (with-current-buffer notes-buf (save-buffer))))))
       (deactivate-mark)
       (org-remark-highlights-housekeep)
       (org-remark-highlights-sort)
       (setq org-remark-source-setup-done t)
-      ;; Save the notes buffer
-      (let ((notes-buf (find-file-noselect (org-remark-notes-get-file-name))))
-        (unless (eq notes-buf (current-buffer))
-          (with-current-buffer notes-buf (save-buffer))))
       ;; Return overlay
       ov)))
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]