diff options
author | Glenn Morris <rgm@gnu.org> | 2014-09-07 22:57:24 -0700 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2014-09-07 22:57:24 -0700 |
commit | 6e82d877a4a59feb4390baeb2ccc57e7cd03593d (patch) | |
tree | e5757c7407c67d6906c3e5760a79312575544cac /lisp/calendar/calendar.el | |
parent | 938aed6ef8c0f6ad609c791b1549580b261a5f12 (diff) | |
download | emacs-6e82d877a4a59feb4390baeb2ccc57e7cd03593d.tar.gz |
* calendar.el (calendar-basic-setup): Avoid clobbering calendar with diary.
Fixes: debbugs:18381
Diffstat (limited to 'lisp/calendar/calendar.el')
-rw-r--r-- | lisp/calendar/calendar.el | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/lisp/calendar/calendar.el b/lisp/calendar/calendar.el index 57cb488a838..3fb98452579 100644 --- a/lisp/calendar/calendar.el +++ b/lisp/calendar/calendar.el @@ -1,7 +1,6 @@ ;;; calendar.el --- calendar functions -;; Copyright (C) 1988-1995, 1997, 2000-2014 Free Software Foundation, -;; Inc. +;; Copyright (C) 1988-1995, 1997, 2000-2014 Free Software Foundation, Inc. ;; Author: Edward M. Reingold <reingold@cs.uiuc.edu> ;; Maintainer: Glenn Morris <rgm@gnu.org> @@ -1432,7 +1431,12 @@ display the generated calendar." (calendar-generate-window month year) (if (and calendar-view-diary-initially-flag (calendar-date-is-visible-p date)) - (diary-view-entries)))) + ;; Do not clobber the calendar with the diary, if the diary + ;; has previously been shown in the window that now shows the + ;; calendar (bug#18381). + (let ((display-buffer-overriding-action + '(nil . ((inhibit-same-window . t))))) + (diary-view-entries))))) (if calendar-view-holidays-initially-flag (let* ((diary-buffer (get-file-buffer diary-file)) (diary-window (if diary-buffer (get-buffer-window diary-buffer))) |