]> git.eshelyaron.com Git - emacs.git/commitdiff
Use pop-to-buffer-same-window instead of switch-to-buffer
authorBastian Beischer <bastian.beischer@gmail.com>
Wed, 18 Oct 2017 23:44:46 +0000 (02:44 +0300)
committerDmitry Gutov <dgutov@yandex.ru>
Wed, 18 Oct 2017 23:45:17 +0000 (02:45 +0300)
* lisp/cedet/semantic/decorate/include.el
(semantic-decoration-include-visit):
Use pop-to-buffer-same-window instead of switch-to-buffer
(bug#28645).

* lisp/cedet/semantic/analyze/refs.el
(semantic-analyze-proto-impl-toggle): Same.

* lisp/cedet/semantic/senator.el (senator-go-to-up-reference):
Same.

* lisp/cedet/semantic/mru-bookmark.el (semantic-mrub-visit):
Same.

* lisp/cedet/semantic/complete.el (semantic-complete-jump):
Same.

Copyright-paperwork-exempt: yes

lisp/cedet/semantic/analyze/refs.el
lisp/cedet/semantic/complete.el
lisp/cedet/semantic/decorate/include.el
lisp/cedet/semantic/mru-bookmark.el
lisp/cedet/semantic/senator.el

index 55fcd8304335ded059ddbcbdbaff1e31f8956c2f..a58479f5054a22f9b9794f14941cc1ef93ffd01c 100644 (file)
@@ -348,7 +348,7 @@ Only works for tags in the global namespace."
 
     (push-mark)
     (semantic-go-to-tag target)
-    (switch-to-buffer (current-buffer))
+    (pop-to-buffer-same-windown (current-buffer))
     (semantic-momentary-highlight-tag target))
   )
 
index ff8e61e54dcd9e5ec14bde203b9d28fd8f5df8f1..325ca1f44145d7ad07d3e8864700a61a15e989db 100644 (file)
@@ -2120,7 +2120,7 @@ completion works."
     (when (semantic-tag-p tag)
       (push-mark)
       (semantic-go-to-tag tag)
-      (switch-to-buffer (current-buffer))
+      (pop-to-buffer-same-window (current-buffer))
       (semantic-momentary-highlight-tag tag)
       (message "%S: %s "
               (semantic-tag-class tag)
index 6876e5f3a4624a039a138550ca5a170fdb3d0745..9f1825d4208735d0a2a065866b22bda2cc5c4441 100644 (file)
@@ -467,7 +467,7 @@ its contents.
        (error "Could not location include %s"
               (semantic-tag-name tag)))
        ((get-file-buffer file)
-       (switch-to-buffer (get-file-buffer file)))
+       (pop-to-buffer-same-window (get-file-buffer file)))
        ((stringp file)
        (find-file file))
        ))))
index 5fa58e08ea62f5920426cec810e330fb4314b456..24863de01b1de2c7ac50749d0fdfa2aff9eac879 100644 (file)
@@ -113,7 +113,7 @@ Uses `semantic-go-to-tag' and highlighting."
          (forward-char o))
       (error nil))
     ;; make it visible
-    (switch-to-buffer (current-buffer))
+    (pop-to-buffer-same-window (current-buffer))
     (semantic-momentary-highlight-tag tag)
     ))
 
index e86658628b51fbe65f762f59cdde9f6375e2c489..70e04475ab260237c300ddc878db5c9dceebdb9b 100644 (file)
@@ -530,11 +530,11 @@ Some tags such as includes have other reference features."
        ;; A tag
        ((semantic-tag-p result)
        (semantic-go-to-tag result)
-       (switch-to-buffer (current-buffer))
+       (pop-to-buffer-same-window (current-buffer))
        (semantic-momentary-highlight-tag result))
        ;; Buffers
        ((bufferp result)
-       (switch-to-buffer result)
+       (pop-to-buffer-same-window result)
        (pulse-momentary-highlight-one-line (point)))
        ;; Files
        ((and (stringp result) (file-exists-p result))