aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2013-12-17 13:11:37 -0500
committerStefan Monnier2013-12-17 13:11:37 -0500
commit2d6b6005bcf3cc4ece90c0d19a645ca3ae1940ea (patch)
tree4d3bf8488f89aa8358c895aea270be5d973a271e
parent60e62dc596e0603397c416cd82c4d4512565fa38 (diff)
downloademacs-2d6b6005bcf3cc4ece90c0d19a645ca3ae1940ea.tar.gz
emacs-2d6b6005bcf3cc4ece90c0d19a645ca3ae1940ea.zip
* lisp/window.el (window--pixel-to-total): Remove unused `mini' var.
(maximize-window, minimize-window): Remove unused `pixelwise' arg. (split-window): Remove unused `new' var. (window--display-buffer): Remove unused `frame' and `delta' vars. (fit-window-to-buffer): Remove unused vars `frame', `display-height', and display-width'.
-rw-r--r--lisp/ChangeLog9
-rw-r--r--lisp/window.el22
2 files changed, 17 insertions, 14 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 763136cb423..86b52fe5339 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,12 @@
12013-12-17 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * window.el (window--pixel-to-total): Remove unused `mini' var.
4 (maximize-window, minimize-window): Remove unused `pixelwise' arg.
5 (split-window): Remove unused `new' var.
6 (window--display-buffer): Remove unused `frame' and `delta' vars.
7 (fit-window-to-buffer): Remove unused vars `frame', `display-height',
8 and display-width'.
9
12013-12-17 Martin Rudalics <rudalics@gmx.at> 102013-12-17 Martin Rudalics <rudalics@gmx.at>
2 11
3 * dired.el (dired-mark-pop-up): 12 * dired.el (dired-mark-pop-up):
diff --git a/lisp/window.el b/lisp/window.el
index c6238ff3516..ffc12930728 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -2143,8 +2143,7 @@ Optional argument HORIZONTAL non-nil means assign new total
2143window widths from pixel widths." 2143window widths from pixel widths."
2144 (setq frame (window-normalize-frame frame)) 2144 (setq frame (window-normalize-frame frame))
2145 (let ((root (frame-root-window)) 2145 (let ((root (frame-root-window))
2146 (char-size (frame-char-size frame horizontal)) 2146 (char-size (frame-char-size frame horizontal)))
2147 (mini (minibuffer-window frame)))
2148 (set-window-new-total 2147 (set-window-new-total
2149 root (window--pixel-to-size 2148 root (window--pixel-to-size
2150 root (window-size root horizontal t) horizontal)) 2149 root (window-size root horizontal t) horizontal))
@@ -3040,7 +3039,7 @@ Also see the `window-min-height' variable."
3040 (window-max-delta nil horizontal)) 3039 (window-max-delta nil horizontal))
3041 horizontal))))) 3040 horizontal)))))
3042 3041
3043(defun maximize-window (&optional window pixelwise) 3042(defun maximize-window (&optional window)
3044 "Maximize WINDOW. 3043 "Maximize WINDOW.
3045Make WINDOW as large as possible without deleting any windows. 3044Make WINDOW as large as possible without deleting any windows.
3046WINDOW must be a valid window and defaults to the selected one. 3045WINDOW must be a valid window and defaults to the selected one.
@@ -3056,7 +3055,7 @@ WINDOW pixelwise."
3056 window (window-max-delta window t nil nil nil nil window-resize-pixelwise) 3055 window (window-max-delta window t nil nil nil nil window-resize-pixelwise)
3057 t nil window-resize-pixelwise)) 3056 t nil window-resize-pixelwise))
3058 3057
3059(defun minimize-window (&optional window pixelwise) 3058(defun minimize-window (&optional window)
3060 "Minimize WINDOW. 3059 "Minimize WINDOW.
3061Make WINDOW as small as possible without deleting any windows. 3060Make WINDOW as small as possible without deleting any windows.
3062WINDOW must be a valid window and defaults to the selected one. 3061WINDOW must be a valid window and defaults to the selected one.
@@ -4230,7 +4229,7 @@ frame. The selected window is not changed by this function."
4230 (old-pixel-size (window-size window horizontal t)) 4229 (old-pixel-size (window-size window horizontal t))
4231 ;; `new-size' is the specified or calculated size of the 4230 ;; `new-size' is the specified or calculated size of the
4232 ;; new window. 4231 ;; new window.
4233 new-pixel-size new new-parent new-normal) 4232 new-pixel-size new-parent new-normal)
4234 (cond 4233 (cond
4235 ((not pixel-size) 4234 ((not pixel-size)
4236 (setq new-pixel-size 4235 (setq new-pixel-size
@@ -5758,8 +5757,7 @@ live."
5758 (set-window-dedicated-p window dedicated)) 5757 (set-window-dedicated-p window dedicated))
5759 (when (memq type '(window frame)) 5758 (when (memq type '(window frame))
5760 (set-window-prev-buffers window nil))) 5759 (set-window-prev-buffers window nil)))
5761 (let ((frame (window-frame window)) 5760 (let ((parameter (window-parameter window 'quit-restore))
5762 (parameter (window-parameter window 'quit-restore))
5763 (height (cdr (assq 'window-height alist))) 5761 (height (cdr (assq 'window-height alist)))
5764 (width (cdr (assq 'window-width alist))) 5762 (width (cdr (assq 'window-width alist)))
5765 (size (cdr (assq 'window-size alist)))) 5763 (size (cdr (assq 'window-size alist))))
@@ -5773,8 +5771,7 @@ live."
5773 ((consp size) 5771 ((consp size)
5774 (let ((width (car size)) 5772 (let ((width (car size))
5775 (height (cdr size)) 5773 (height (cdr size))
5776 (frame (window-frame window)) 5774 (frame (window-frame window)))
5777 delta)
5778 (when (and (numberp width) (numberp height)) 5775 (when (and (numberp width) (numberp height))
5779 (set-frame-height 5776 (set-frame-height
5780 frame (+ (frame-height frame) 5777 frame (+ (frame-height frame)
@@ -6379,7 +6376,7 @@ that frame."
6379 (unless (cdr (assq 'inhibit-switch-frame alist)) 6376 (unless (cdr (assq 'inhibit-switch-frame alist))
6380 (window--maybe-raise-frame (window-frame window))))))) 6377 (window--maybe-raise-frame (window-frame window)))))))
6381 6378
6382(defun display-buffer-no-window (buffer alist) 6379(defun display-buffer-no-window (_buffer alist)
6383 "Display BUFFER in no window. 6380 "Display BUFFER in no window.
6384If ALIST has a non-nil `allow-no-window' entry, then don't display 6381If ALIST has a non-nil `allow-no-window' entry, then don't display
6385a window at all. This makes possible to override the default action 6382a window at all. This makes possible to override the default action
@@ -7073,10 +7070,8 @@ accessible position."
7073 max-height min-height max-width min-width)) 7070 max-height min-height max-width min-width))
7074 (with-selected-window window 7071 (with-selected-window window
7075 (let* ((pixelwise window-resize-pixelwise) 7072 (let* ((pixelwise window-resize-pixelwise)
7076 (frame (window-frame))
7077 (char-height (frame-char-height)) 7073 (char-height (frame-char-height))
7078 (char-width (frame-char-width)) 7074 (char-width (frame-char-width))
7079 (display-height (display-pixel-height))
7080 (total-height (window-size window nil pixelwise)) 7075 (total-height (window-size window nil pixelwise))
7081 (body-height (window-body-height window pixelwise)) 7076 (body-height (window-body-height window pixelwise))
7082 (body-width (window-body-width window pixelwise)) 7077 (body-width (window-body-width window pixelwise))
@@ -7131,8 +7126,7 @@ accessible position."
7131 ((and fit-window-to-buffer-horizontally 7126 ((and fit-window-to-buffer-horizontally
7132 (not (window-size-fixed-p window t)) 7127 (not (window-size-fixed-p window t))
7133 (window-combined-p nil t)) 7128 (window-combined-p nil t))
7134 (let* ((display-width (display-pixel-width)) 7129 (let* ((total-width (window-size window nil pixelwise))
7135 (total-width (window-size window nil pixelwise))
7136 (min-width 7130 (min-width
7137 ;; Sanitize MIN-WIDTH. 7131 ;; Sanitize MIN-WIDTH.
7138 (if (numberp min-width) 7132 (if (numberp min-width)