changeset 9413:e54eede71446

(appt-delete-window): Look on all frames for the window. (appt-disp-window): If frame is unsplittable, use display-buffer.
author Richard M. Stallman <rms@gnu.org>
date Sun, 09 Oct 1994 09:19:16 +0000
parents 53898786366f
children fae44b2323fe
files lisp/calendar/appt.el
diffstat 1 files changed, 8 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/calendar/appt.el	Sat Oct 08 22:16:04 1994 +0000
+++ b/lisp/calendar/appt.el	Sun Oct 09 09:19:16 1994 +0000
@@ -366,14 +366,17 @@
 	 (appt-disp-buf (set-buffer (get-buffer-create appt-buffer-name))))
 
     (appt-select-lowest-window)
-    (split-window)
-      
-    (pop-to-buffer appt-disp-buf)
+    (if (cdr (assq 'unsplittable (frame-parameters)))
+	;; In an unsplittable frame, use something somewhere else.
+	(display-buffer appt-disp-buf)
+      ;; Otherwise, split the bottom window and use the lower part.
+      (split-window)
+      (pop-to-buffer appt-disp-buf))
     (setq mode-line-format 
 	  (concat "-------------------- Appointment in "
 		  min-to-app " minutes. " new-time " %-"))
     (insert-string appt-msg)
-    (shrink-window-if-larger-than-buffer (get-buffer-window appt-disp-buf))
+    (shrink-window-if-larger-than-buffer (get-buffer-window appt-disp-buf t))
     (set-buffer-modified-p nil)
     (select-window this-window)
     (if appt-audible
@@ -382,7 +385,7 @@
 (defun appt-delete-window ()
   "Function called to undisplay appointment messages.
 Usually just deletes the appointment buffer."
-  (delete-window (get-buffer-window appt-buffer-name))
+  (delete-window (get-buffer-window appt-buffer-name t))
   (kill-buffer appt-buffer-name)
   (if appt-audible
       (beep 1)))