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

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

[elpa] externals/rec-mode 1982af5 42/98: rec-mode: allow the user to can


From: Stefan Monnier
Subject: [elpa] externals/rec-mode 1982af5 42/98: rec-mode: allow the user to cancel the edit date operation by quitting the calendar window.
Date: Thu, 12 Nov 2020 13:18:37 -0500 (EST)

branch: externals/rec-mode
commit 1982af536ea31a011d284c945b7ea1493fae0df0
Author: Jose E. Marchesi <jemarch@gnu.org>
Commit: Antoine Kalmbach <ane@iki.fi>

    rec-mode: allow the user to cancel the edit date operation by quitting the 
calendar window.
---
 etc/rec-mode.el | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/etc/rec-mode.el b/etc/rec-mode.el
index 610ca38..2a324ff 100644
--- a/etc/rec-mode.el
+++ b/etc/rec-mode.el
@@ -1565,6 +1565,10 @@ will be used for fields of any type."
           (calendar)
           (let ((old-map (current-local-map))
                 (map (copy-keymap calendar-mode-map)))
+            (define-key map "q"
+              `(lambda () (interactive)
+                 (use-local-map (quote ,old-map))
+                 (calendar-exit)))
             (define-key map (kbd "RET")
               `(lambda () (interactive)
                  (let* ((date (calendar-cursor-to-date))



reply via email to

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