Mercurial > emacs
changeset 12060:b163768a998f
Fix cal-x.el to create an empty fancy-diary-buffer, if needed.
author | Edward M. Reingold <reingold@emr.cs.iit.edu> |
---|---|
date | Fri, 02 Jun 1995 14:45:21 +0000 |
parents | b6f64c954ce9 |
children | 017af11017a0 |
files | lisp/calendar/cal-x.el |
diffstat | 1 files changed, 11 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/calendar/cal-x.el Fri Jun 02 14:44:34 1995 +0000 +++ b/lisp/calendar/cal-x.el Fri Jun 02 14:45:21 1995 +0000 @@ -103,11 +103,13 @@ (set-window-dedicated-p (selected-window) 'calendar) (set-window-dedicated-p (display-buffer - (if (memq 'fancy-diary-display diary-display-hook) - fancy-diary-buffer - (get-file-buffer diary-file))) + (if (not (memq 'fancy-diary-display diary-display-hook)) + (get-file-buffer diary-file) + (if (not (bufferp (get-buffer fancy-diary-buffer))) + (make-fancy-diary-buffer)) + fancy-diary-buffer)) 'diary)))))) - + (defun calendar-two-frame-setup (&optional arg) "Start calendar and diary in separate, dedicated frames." (if (not window-system) @@ -136,9 +138,11 @@ (save-excursion (diary)) (set-window-dedicated-p (display-buffer - (if (memq 'fancy-diary-display diary-display-hook) - fancy-diary-buffer - (get-file-buffer diary-file))) + (if (not (memq 'fancy-diary-display diary-display-hook)) + (get-file-buffer diary-file) + (if (not (bufferp (get-buffer fancy-diary-buffer))) + (make-fancy-diary-buffer)) + fancy-diary-buffer)) 'diary))))) (setq special-display-buffer-names