Function: hmouse-swap-buffers

hmouse-swap-buffers is a byte-compiled function defined in hui-window.el.

Signature

(hmouse-swap-buffers)

Documentation

Swap buffers in windows selected with the last Smart Key depress and release.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hui-window.el
(defun hmouse-swap-buffers ()
  "Swap buffers in windows selected with the last Smart Key depress and release."
  (let* ((w1 (if assist-flag assist-key-depress-window
	       action-key-depress-window))
	 (w2 (if assist-flag assist-key-release-window
	       action-key-release-window))
	 (w1-buf (and w1 (window-buffer w1)))
	 (w2-buf (and w2 (window-buffer w2))))
    (cond ((not (and w1 w2))
	   (error "(hmouse-swap-buffers): Last depress or release was not within a window"))
	  ((eq w1 w2))  ;; Do nothing silently.
	  (t ;; Swap window buffers.
	   (set-window-buffer w1 w2-buf)
	   (set-window-buffer w2 w1-buf)))))