# HG changeset patch # User Stefan Monnier # Date 1254720971 0 # Node ID 7e96a7ac3ac000792165ba0990692f7bdc143c58 # Parent 4d75e3e0f1ea5a171967eb24834b5705fd583524 (calendar-basic-setup): Don't call switch-to-buffer in a dedicated window. diff -r 4d75e3e0f1ea -r 7e96a7ac3ac0 lisp/ChangeLog --- a/lisp/ChangeLog Mon Oct 05 04:19:04 2009 +0000 +++ b/lisp/ChangeLog Mon Oct 05 05:36:11 2009 +0000 @@ -1,3 +1,8 @@ +2009-10-05 Stefan Monnier + + * calendar/calendar.el (calendar-basic-setup): Don't call + switch-to-buffer in a dedicated window. + 2009-10-05 Karl Fogel * bookmark.el (bookmark-handle-bookmark): If bookmark has no file, diff -r 4d75e3e0f1ea -r 7e96a7ac3ac0 lisp/calendar/calendar.el --- a/lisp/calendar/calendar.el Mon Oct 05 04:19:04 2009 +0000 +++ b/lisp/calendar/calendar.el Mon Oct 05 05:36:11 2009 +0000 @@ -1321,7 +1321,8 @@ (if (window-splittable-p t) (split-window-horizontally)) (pop-to-buffer calendar-buffer) ;; Has the window already been split vertically? (See bug#4543) - (when (= (window-height) (window-height (frame-root-window))) + (when (and (not (window-dedicated-p)) + (= (window-height) (window-height (frame-root-window)))) (let ((win (split-window-vertically))) ;; Show something else in the upper window. (switch-to-buffer (other-buffer))