From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Danjou Subject: Re: [Accepted] Re: Bug: Jumping to a date in the agenda changes view back to 'day' [7.4 (release_7.4.80.g0e5e5)] Date: Mon, 07 Feb 2011 12:39:17 +0100 Message-ID: <87sjvzaezr.fsf@keller.adm.naquadah.org> References: <20110201115210.6AD9A8783@myhost.localdomain> <87wrlfl1jx.fsf@fastmail.fm> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0243016911==" Return-path: Received: from [140.186.70.92] (port=41918 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PmYND-0000La-2M for emacs-orgmode@gnu.org; Mon, 07 Feb 2011 16:11:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PmVbz-00038Q-Bs for emacs-orgmode@gnu.org; Mon, 07 Feb 2011 13:14:56 -0500 Received: from prometheus.naquadah.org ([212.85.154.174]:35866 helo=mx1.naquadah.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PmVbz-00038D-3v for emacs-orgmode@gnu.org; Mon, 07 Feb 2011 13:14:55 -0500 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Matt Lundin Cc: Bastien Guerry , emacs-orgmode@gnu.org --===============0243016911== Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain On Sat, Feb 05 2011, Matt Lundin wrote: > This results in only a day view because org-agenda-current-span is still > 'day. Here's a proposal fix. I could have setq org-agenda-current-span to nil as a work around, but it seems more logical to just kill all the local variables. That is, a custom agenda view would not keep any of the local variable of the previous agenda, which seems logical to me. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-org-agenda-kill-local-variables-in-agenda-view.patch Content-Transfer-Encoding: quoted-printable From=20b48fc7c395dffea60df20c23b26e362ac0354b01 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Mon, 7 Feb 2011 12:36:42 +0100 Subject: [PATCH] org-agenda: kill local variables in agenda view * org-agenda.el (org-agenda): Kill all local variables. This assures we are not keeping buffer variable from an old agenda view when switching to a new custom agenda. Signed-off-by: Julien Danjou =2D-- lisp/org-agenda.el | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index d146f83..9a3d953 100644 =2D-- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -2161,6 +2161,8 @@ Pressing `<' twice means to restrict to the current s= ubtree or region (put 'org-agenda-redo-command 'org-lprops nil) ;; Remember where this call originated (setq org-agenda-last-dispatch-buffer (current-buffer)) + ;; Remove all local variables + (kill-all-local-variables) (unless keys (setq ans (org-agenda-get-restriction-and-command prefix-descriptions) keys (car ans) =2D-=20 1.7.2.3 --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable =2D-=20 Julien Danjou =E2=9D=B1 http://julien.danjou.info --=-=-=-- --==-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAEBAgAGBQJNUDaYAAoJEGEbqVCLeKXC11YP/j3iD7l3fSAx0NHDTRaGaL2F n+A27QOqWvJwRrsjti4Y8BtG5QnivHLFmtGCFduUW8hCbvS+v7jMfuy8WSF0vqke gAHSmI9S8Drew8xBehdCqtVnWb7m585mb37/pNl74lv1x0gCgCswZS0bA2R8L1Ez XwyUnCmPOkkbGvPtqAMu8F5s0crWJz2GORtwN09YkKyZTb7EZkBmsKzCac88NJwk oSJlYNb+RqAg4fZk2+csQXjt/zssqO+Z4LkYT+ZcU3AjDR1C2SvuhFZ1FvPOvuEI In+bQuwhNiP0cfP1FwuH6J85nQIavciAfvUrtTTovMLpFtsv4YAiBwstBkT0W5kw aE2WITAI+1Gx0/u/0vdddKROGVTMFShPRQfvIbN2tr2dN+aQJNjYnjm/oRa9c+vW DZkJi5UfyavAOx0uagjROYVR9eYKejD6GiK43s4qskjAi4xOiylBNlCdaWoW18L+ wK6rNPWmrGTy6e47kvrxGOnCfLG1ESFBSQQT8+ziYUY/I5zvoaoJavJnx+Vvk1nG tS0MlTYUWoeeVAjlJJ8VvDuvz7qQXjM7YXjj3SpyhqT1AqroZ6UQC9CSyoWfC6ac RaJttCyYxt9BSA34HJORoGKfLTIXz/tJdjHwXgISzXKId4BqN5Jr3IEqM3aI46y3 fkgnnip3i+4JWvsldGFG =yun8 -----END PGP SIGNATURE----- --==-=-=-- --===============0243016911== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============0243016911==--