From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nikolai Weibull Subject: [PATCH 1/2] Redo Agenda in more cases even in sticky mode Date: Thu, 20 Aug 2015 20:22:14 +0200 Message-ID: <1440094934-33394-1-git-send-email-now@disu.se> References: <87h9umi5vb.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37510) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZSUTp-0001H7-1M for emacs-orgmode@gnu.org; Thu, 20 Aug 2015 14:22:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZSUTl-0006Be-6T for emacs-orgmode@gnu.org; Thu, 20 Aug 2015 14:22:24 -0400 Received: from smtprelay-b32.telenor.se ([213.150.131.21]:35765) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZSUTl-0006BX-0Z for emacs-orgmode@gnu.org; Thu, 20 Aug 2015 14:22:21 -0400 Received: from ipb4.telenor.se (ipb4.telenor.se [195.54.127.167]) by smtprelay-b32.telenor.se (Postfix) with ESMTP id 77E73EEECF for ; Thu, 20 Aug 2015 20:22:19 +0200 (CEST) In-Reply-To: <87h9umi5vb.fsf@nicolasgoaziou.fr> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Cc: Nikolai Weibull * org-agenda.el (org-agenda-maybe-redo): Test for org-agenda-this-buffer-name as well. The Agenda buffer will have a different name if it=E2=80=99s in sticky mo= de, but some commands that alter the agenda should still redo it, for example, org-agenda-remove-restriction-lock, just like org-agenda-filter-by-category does. --- lisp/org-agenda.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index 07b77ac..5fd1cd4 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -7169,7 +7169,9 @@ in the file. Otherwise, restriction will be to the= current subtree." =20 (defun org-agenda-maybe-redo () "If there is any window showing the agenda view, update it." - (let ((w (get-buffer-window org-agenda-buffer-name t)) + (let ((w (get-buffer-window (or org-agenda-this-buffer-name + org-agenda-buffer-name) + t)) (w0 (selected-window))) (when w (select-window w) --=20 2.5.0