From: me@bcc32.com
To: emacs-orgmode@gnu.org
Cc: "Aaron L. Zeng" <me@bcc32.com>
Subject: [PATCH] org-clock.el: Clear org-clock-current-task on clock cancel
Date: Sat, 15 Jun 2019 01:20:15 -0400 [thread overview]
Message-ID: <20190615052015.8995-1-me@bcc32.com> (raw)
From: "Aaron L. Zeng" <me@bcc32.com>
* org-mode/lisp/org-clock.el (org-clock-cancel): Clear
`org-clock-current-task' when a clock is canceled.
This variable is used by some mode line packages (e.g.,
spaceline-all-the-icons), so not clearing the variable incorrectly
displays the previous task as ongoing.
---
lisp/org-clock.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index 12b412f7b..3d8e1136a 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -1741,6 +1741,7 @@ Optional argument N tells to change by that many units."
(sit-for 2)))
(move-marker org-clock-marker nil)
(move-marker org-clock-hd-marker nil)
+ (setq org-clock-current-task nil)
(setq global-mode-string
(delq 'org-mode-line-string global-mode-string))
(org-clock-restore-frame-title-format)
--
2.20.1 (Apple Git-117)
next reply other threads:[~2019-06-15 5:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-15 5:20 me [this message]
2019-06-15 9:56 ` [PATCH] org-clock.el: Clear org-clock-current-task on clock cancel Nicolas Goaziou
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190615052015.8995-1-me@bcc32.com \
--to=me@bcc32.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.