unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#32475: 27.0.50; Multiple log-view-mode buffers
@ 2018-08-19 21:31 Juri Linkov
  2018-08-30 22:20 ` Juri Linkov
  0 siblings, 1 reply; 2+ messages in thread
From: Juri Linkov @ 2018-08-19 21:31 UTC (permalink / raw)
  To: 32475

[-- Attachment #1: Type: text/plain, Size: 274 bytes --]

To support the ability to create multiple *vc-change-log* buffers
with customization like

  (add-hook 'log-view-mode-hook 'rename-uniquely)

vc-log-internal-common needs an improvement to remember and reuse
the buffer object, instead of searching the same buffer by name:


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: vc-log-internal-common.1.patch --]
[-- Type: text/x-diff, Size: 1131 bytes --]

diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
index b2bedfae93..487594b2d5 100644
--- a/lisp/vc/vc.el
+++ b/lisp/vc/vc.el
@@ -2268,11 +2268,11 @@ vc-log-internal-common
 			       setup-buttons-func
 			       goto-location-func
 			       rev-buff-func)
-  (let (retval)
-    (with-current-buffer (get-buffer-create buffer-name)
+  (let (retval (buffer (get-buffer-create buffer-name)))
+    (with-current-buffer buffer
       (set (make-local-variable 'vc-log-view-type) type))
     (setq retval (funcall backend-func backend buffer-name type files))
-    (with-current-buffer (get-buffer buffer-name)
+    (with-current-buffer buffer
       (let ((inhibit-read-only t))
 	;; log-view-mode used to be called with inhibit-read-only bound
 	;; to t, so let's keep doing it, just in case.
@@ -2283,7 +2283,7 @@ vc-log-internal-common
 	     rev-buff-func)))
     ;; Display after setting up major-mode, so display-buffer-alist can know
     ;; the major-mode.
-    (pop-to-buffer buffer-name)
+    (pop-to-buffer buffer)
     (vc-run-delayed
      (let ((inhibit-read-only t))
        (funcall setup-buttons-func backend files retval)

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#32475: 27.0.50; Multiple log-view-mode buffers
  2018-08-19 21:31 bug#32475: 27.0.50; Multiple log-view-mode buffers Juri Linkov
@ 2018-08-30 22:20 ` Juri Linkov
  0 siblings, 0 replies; 2+ messages in thread
From: Juri Linkov @ 2018-08-30 22:20 UTC (permalink / raw)
  To: 32475-done

> To support the ability to create multiple *vc-change-log* buffers
> with customization like
>
>   (add-hook 'log-view-mode-hook 'rename-uniquely)
>
> vc-log-internal-common needs an improvement to remember and reuse
> the buffer object, instead of searching the same buffer by name:

Done in 15006cf1dd.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-08-30 22:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-19 21:31 bug#32475: 27.0.50; Multiple log-view-mode buffers Juri Linkov
2018-08-30 22:20 ` Juri Linkov

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).