[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r104603: Improve cohabitation of pop-
From: |
martin rudalics |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r104603: Improve cohabitation of pop-up-frames and second argument of display-buffer (bug#8865). |
Date: |
Thu, 16 Jun 2011 09:31:51 +0200 |
User-agent: |
Bazaar (2.3.1) |
------------------------------------------------------------
revno: 104603
committer: martin rudalics <address@hidden>
branch nick: trunk
timestamp: Thu 2011-06-16 09:31:51 +0200
message:
Improve cohabitation of pop-up-frames and second argument of display-buffer
(bug#8865).
* window.el (display-buffer-normalize-specifiers-1): Respect
current value of pop-up-frames for most reasonable values of
second argument of display-buffer (Bug#8865).
modified:
lisp/ChangeLog
lisp/window.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2011-06-15 20:44:45 +0000
+++ b/lisp/ChangeLog 2011-06-16 07:31:51 +0000
@@ -1,3 +1,9 @@
+2011-06-16 Martin Rudalics <address@hidden>
+
+ * window.el (display-buffer-normalize-specifiers-1): Respect
+ current value of pop-up-frames for most reasonable values of
+ second argument of display-buffer (Bug#8865).
+
2011-06-15 Stefan Monnier <address@hidden>
* pcmpl-rpm.el (pcomplete/rpm): Minor simplification.
=== modified file 'lisp/window.el'
--- a/lisp/window.el 2011-06-15 17:20:36 +0000
+++ b/lisp/window.el 2011-06-16 07:31:51 +0000
@@ -3453,9 +3453,8 @@
;; (bw-finetune wins)
;; (message "Done in %d rounds" round)
))
-
-
-
+
+;;; Displaying buffers.
(defconst display-buffer-default-specifiers
'((reuse-window nil same visible)
(pop-up-window (largest . nil) (lru . nil))
@@ -4909,9 +4908,12 @@
(defun display-buffer-normalize-specifiers-1 (specifiers)
"Subroutine of `display-buffer-normalize-specifiers'.
SPECIFIERS is the SPECIFIERS argument of `display-buffer'."
- (let (normalized)
+ (let (normalized entry)
(cond
+ ((not specifiers)
+ nil)
((listp specifiers)
+ ;; If SPECIFIERS is a list, we assume it is a list of specifiers.
(dolist (specifier specifiers)
(cond
((consp specifier)
@@ -4924,21 +4926,17 @@
(dolist (item (cdr entry))
(setq normalized (cons item normalized)))))))
;; Reverse list.
- (setq normalized (nreverse normalized)))
- ;; The two cases below must come from the SPECIFIERS argument of
- ;; `display-buffer'.
- ((eq specifiers 't)
- ;; Historically t means "other window". Eventually we should get
- ;; rid of this.
- (setq normalized
- (cdr (assq 'other-window display-buffer-macro-specifiers))
- normalized))
- ((symbolp specifiers)
- ;; We allow scalar specifiers in calls of `display-buffer'.
- (let ((entry (assq specifiers display-buffer-macro-specifiers)))
- (when entry (setq normalized (cdr entry))))))
-
- normalized))
+ (nreverse normalized))
+ ((and (not (eq specifiers 'other-window))
+ (setq entry (assq specifiers display-buffer-macro-specifiers)))
+ ;; A macro specifier.
+ (cdr entry))
+ ((memq pop-up-frames '(nil unset))
+ ;; Pop up a new window.
+ (cdr (assq 'other-window display-buffer-macro-specifiers)))
+ (t
+ ;; Pop up a new frame.
+ (cdr (assq 'other-frame display-buffer-macro-specifiers))))))
(defun display-buffer-normalize-specifiers-2 (&optional buffer-or-name)
"Subroutine of `display-buffer-normalize-specifiers'.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r104603: Improve cohabitation of pop-up-frames and second argument of display-buffer (bug#8865).,
martin rudalics <=