Avoid errors with recentering in 'skeleton-insert'
* lisp/skeleton.el (skeleton-insert): Don't recenter if we are running in a buffer other than the one displayed in the selected window. (Bug#31950)
This commit is contained in:
@@ -268,7 +268,8 @@ available:
|
||||
(or (eolp) (not skeleton-end-newline) (newline-and-indent))
|
||||
(run-hooks 'skeleton-end-hook)
|
||||
(sit-for 0)
|
||||
(or (pos-visible-in-window-p beg)
|
||||
(or (not (eq (window-buffer) (current-buffer)))
|
||||
(pos-visible-in-window-p beg)
|
||||
(progn
|
||||
(goto-char beg)
|
||||
(recenter 0)))
|
||||
|
||||
Reference in New Issue
Block a user