Function: action-key-modeline

action-key-modeline is a byte-compiled function defined in hui-window.el.

Signature

(action-key-modeline)

Documentation

Handle Action Key depresses on a window mode line.

If the Action Key is:
 (1) clicked on the first blank character of a window's modeline,
     the window's buffer is buried (placed at bottom of buffer list);
 (2) clicked on right edge of a window's modeline,
     the Info buffer is displayed, or if already displayed and the
     modeline clicked belongs to a window displaying Info, the Info
     buffer is hidden;
 (3) clicked on the buffer id of a window's modeline, Dired is run
     on the current directory, replacing the window's buffer;
     successive clicks walk up the directory tree
 (4) clicked anywhere in the middle of a window's modeline,
     the function given by action-key-modeline-function is called;
 (5) dragged vertically from non-bottommost modeline to within a window,
     the modeline is moved to point of key release, thereby resizing
     its window and potentially its vertical neighbors.
 (6) dragged from a bottommost modeline in a frame with a non-nil
     drag-with-mode-line parameter (use frame-set-parameter),
     moves the frame as the drag occurs.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hui-window.el
(defun action-key-modeline ()
  "Handle Action Key depresses on a window mode line.
If the Action Key is:
 (1) clicked on the first blank character of a window's modeline,
     the window's buffer is buried (placed at bottom of buffer list);
 (2) clicked on right edge of a window's modeline,
     the Info buffer is displayed, or if already displayed and the
     modeline clicked belongs to a window displaying Info, the Info
     buffer is hidden;
 (3) clicked on the buffer id of a window's modeline, Dired is run
     on the current directory, replacing the window's buffer;
     successive clicks walk up the directory tree
 (4) clicked anywhere in the middle of a window's modeline,
     the function given by `action-key-modeline-function' is called;
 (5) dragged vertically from non-bottommost modeline to within a window,
     the modeline is moved to point of key release, thereby resizing
     its window and potentially its vertical neighbors.
 (6) dragged from a bottommost modeline in a frame with a non-nil
     `drag-with-mode-line' parameter (use `frame-set-parameter'),
     moves the frame as the drag occurs."
  ;; Modeline window resizing is now handled in action-key-depress
  ;; via a call to mouse-drag-mode-line, providing live visual
  ;; feedback.
  (let ((w (smart-window-of-coords action-key-depress-args)))
    (if w (select-window w))
    (when (hmouse-modeline-click)
      (cond ((hmouse-emacs-at-modeline-buffer-id-p)
	     (funcall action-key-modeline-buffer-id-function))
	    ((hmouse-release-left-edge)
	     (funcall action-key-modeline-left-edge-function))
	    ((hmouse-release-right-edge)
	     (funcall action-key-modeline-right-edge-function))
	    (t (funcall action-key-modeline-function))))))