]> git.eshelyaron.com Git - emacs.git/commitdiff
In debug record height of debugger window also when debugger will be back (Bug#8789).
authorMartin Rudalics <rudalics@gmx.at>
Fri, 19 Oct 2012 09:28:50 +0000 (11:28 +0200)
committerMartin Rudalics <rudalics@gmx.at>
Fri, 19 Oct 2012 09:28:50 +0000 (11:28 +0200)
* emacs-lisp/debug.el (debug): Record height of debugger window
also when debugger will be back (Bug#8789).

lisp/ChangeLog
lisp/emacs-lisp/debug.el

index 46336af6e7161ad5e26482b40e325bfcf86f9db6..f9d9ad4b03d68631c31bc7f1bf1889a30782d76f 100644 (file)
@@ -1,3 +1,8 @@
+2012-10-19  Martin Rudalics  <rudalics@gmx.at>
+
+       * emacs-lisp/debug.el (debug): Record height of debugger window
+       also when debugger will be back (Bug#8789).
+
 2012-10-18  Chong Yidong  <cyd@gnu.org>
 
        * progmodes/gdb-mi.el (gdb-display-buffer-other-frame-action):
index c30ccf3315eafe67766410c1701a297de418c512..c04e68c0cfa30a2310cd6b672e286e67a8f050de 100644 (file)
@@ -267,15 +267,17 @@ first will be printed into the backtrace buffer."
                ;; Make sure we unbind buffer-read-only in the right buffer.
                (save-excursion
                  (recursive-edit))))
+         (when (and (window-live-p debugger-window)
+                    (eq (window-buffer debugger-window) debugger-buffer))
+           ;; Record height of debugger window.
+           (setq debugger-previous-window-height
+                 (window-total-size debugger-window)))
          (if debugger-will-be-back
              ;; Restore previous window configuration (Bug#12623).
              (set-window-configuration window-configuration)
            (when (and (window-live-p debugger-window)
                       (eq (window-buffer debugger-window) debugger-buffer))
              (progn
-               ;; Record height of debugger window.
-               (setq debugger-previous-window-height
-                     (window-total-size debugger-window))
                ;; Unshow debugger-buffer.
                (quit-restore-window debugger-window debugger-bury-or-kill)
                ;; Restore current buffer (Bug#12502).