Commit 8c7727c3 authored by Martin Rudalics's avatar Martin Rudalics
Browse files

Fix bug#12731 in mouse-drag-line.

* mouse.el (mouse-drag-line): Move last form into preceding when
clause (Bug#12731).

* help.el (resize-temp-buffer-window): Fix doc-string.
parent b75897ba
2012-10-26 Martin Rudalics <rudalics@gmx.at>
* mouse.el (mouse-drag-line): Move last form into preceding when
clause (Bug#12731).
* help.el (resize-temp-buffer-window): Fix doc-string.
2012-10-25 David Engster <deng@randomsample.de> 2012-10-25 David Engster <deng@randomsample.de>
   
* emacs-lisp/eieio.el (eieio-update-lisp-imenu-expression): * emacs-lisp/eieio.el (eieio-update-lisp-imenu-expression):
......
...@@ -1012,8 +1012,8 @@ WINDOW can be any live window and defaults to the selected one. ...@@ -1012,8 +1012,8 @@ WINDOW can be any live window and defaults to the selected one.
Do not make WINDOW higher than `temp-buffer-max-height' nor Do not make WINDOW higher than `temp-buffer-max-height' nor
smaller than `window-min-height'. Do nothing if WINDOW is not smaller than `window-min-height'. Do nothing if WINDOW is not
vertically combined or some of its contents are scrolled out of vertically combined, some of its contents are scrolled out of
view." view, or WINDOW was not created by `display-buffer'."
(setq window (window-normalize-window window t)) (setq window (window-normalize-window window t))
(let ((buffer-name (buffer-name (window-buffer window)))) (let ((buffer-name (buffer-name (window-buffer window))))
(let ((height (if (functionp temp-buffer-max-height) (let ((height (if (functionp temp-buffer-max-height)
...@@ -1022,11 +1022,12 @@ view." ...@@ -1022,11 +1022,12 @@ view."
temp-buffer-max-height)) temp-buffer-max-height))
(quit-cadr (cadr (window-parameter window 'quit-restore)))) (quit-cadr (cadr (window-parameter window 'quit-restore))))
(cond (cond
;; Don't resize WINDOW if it showed another buffer before. ;; Resize WINDOW iff it was split off by `display-buffer'.
((and (eq quit-cadr 'window) ((and (eq quit-cadr 'window)
(pos-visible-in-window-p (point-min) window) (pos-visible-in-window-p (point-min) window)
(window-combined-p window)) (window-combined-p window))
(fit-window-to-buffer window height)) (fit-window-to-buffer window height))
;; Resize FRAME iff it was created by `display-buffer'.
((and fit-frame-to-buffer ((and fit-frame-to-buffer
(eq quit-cadr 'frame) (eq quit-cadr 'frame)
(eq window (frame-root-window window))) (eq window (frame-root-window window)))
......
...@@ -517,8 +517,8 @@ must be one of the symbols `header', `mode', or `vertical'." ...@@ -517,8 +517,8 @@ must be one of the symbols `header', `mode', or `vertical'."
;; If mouse-2 has never been done by the user, it doesn't have ;; If mouse-2 has never been done by the user, it doesn't have
;; the necessary property to be interpreted correctly. ;; the necessary property to be interpreted correctly.
(put 'mouse-2 'event-kind 'mouse-click) (put 'mouse-2 'event-kind 'mouse-click)
(setcar event 'mouse-2)) (setcar event 'mouse-2)
(push event unread-command-events))) (push event unread-command-events))))
(defun mouse-drag-mode-line (start-event) (defun mouse-drag-mode-line (start-event)
"Change the height of a window by dragging on the mode line." "Change the height of a window by dragging on the mode line."
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment