[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/tmr 448be30775 09/14: Improve tmr-clone: Only prompt fo
From: |
ELPA Syncer |
Subject: |
[elpa] externals/tmr 448be30775 09/14: Improve tmr-clone: Only prompt for description if pressing C-u C-u |
Date: |
Mon, 27 Jun 2022 12:58:04 -0400 (EDT) |
branch: externals/tmr
commit 448be307750dfc7543e5dbd9ff3c247d6e1b658c
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Protesilaos Stavrou <info@protesilaos.com>
Improve tmr-clone: Only prompt for description if pressing C-u C-u
---
tmr.el | 21 +++++++++------------
1 file changed, 9 insertions(+), 12 deletions(-)
diff --git a/tmr.el b/tmr.el
index 546ac831bc..e43a6a38fa 100644
--- a/tmr.el
+++ b/tmr.el
@@ -371,25 +371,22 @@ user uses a prefix argument (\\[universal-argument])."
;;;###autoload
(defun tmr-clone (timer &optional prompt)
"Create a new timer by cloning TIMER.
-With optional PROMPT, such as a prefix argument, ask for
-confirmation about the duration and the description. The
-description is asked only if TIMER had one.
+With optional PROMPT, such as a prefix argument (C-u), ask for
+confirmation about the duration. The description is asked only
+when the prefix argument is given twice (C-u C-u).
Without a PROMPT, clone TIMER outright."
(interactive
(list
(tmr--read-timer nil #'tmr--long-description-for-clonable-timer)
current-prefix-arg))
- (let ((description (tmr--timer-description timer)))
- (cond
- (prompt
- (tmr
+ (tmr
+ (if prompt
(tmr--read-duration (format "%s" (tmr--timer-input timer)))
- (when description (tmr--description-prompt description))))
- (t
- (tmr
- (format "%s" (tmr--timer-input timer))
- (tmr--timer-description timer))))))
+ (format "%s" (tmr--timer-input timer)))
+ (if (equal prompt '(16))
+ (tmr--description-prompt (tmr--timer-description timer))
+ (tmr--timer-description timer))))
(provide 'tmr)
;;; tmr.el ends here
- [elpa] externals/tmr updated (704242b6ba -> 907756ce8d), ELPA Syncer, 2022/06/27
- [elpa] externals/tmr bdd99767bb 03/14: Add tmr-tabulated--refresh, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 38c9089597 08/14: tmr-remove-finished: Add autoload, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 9f0dee563b 06/14: Move tmr-sound.el back into tmr.el, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr cfd798b066 11/14: Add tmr-reschedule and tmr-edit-description, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 907756ce8d 14/14: Acknowledge Daniel Mendler for the latest patches, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 448be30775 09/14: Improve tmr-clone: Only prompt for description if pressing C-u C-u,
ELPA Syncer <=
- [elpa] externals/tmr 6f3b096f2c 13/14: Greatly simplify tmr-tabulated, reuse tmr--read-timer, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 58d30c4896 12/14: Remove single line functions which were used only once, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 58224191d0 01/14: Rename struct tmr-timer to tmr--timer, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr e18496d187 07/14: Add tmr--update-hook, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr e9c6c8861f 02/14: Get rid of tmr-descriptions-list, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 9974a28933 04/14: Remove unnecessary declare-function, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr d6d5e4d22d 05/14: Warn if dbus is unavailable, ELPA Syncer, 2022/06/27
- [elpa] externals/tmr 92d6163dd0 10/14: Remove no-hooks argument, ELPA Syncer, 2022/06/27