emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Suggestion: Add discussion of input focus handling to select-window;


From: Robert Weiner
Subject: Re: Suggestion: Add discussion of input focus handling to select-window; add select-frame-window
Date: Tue, 12 Dec 2017 16:29:23 -0500

On Tue, Dec 12, 2017 at 3:40 PM, Stefan Monnier <address@hidden> wrote:
> ​The same issue exists with save-selected-window except that it applies to
> the start selected window rather than a new one.  Another macro,
> save-selected-frame-window, would keep input from switching to another
> frame within its scope since this is not part of save-selected-window's
> behavior.

You mean some kind of `save-frame-focus` macro (tho that name itself
can be confusing since it seems to refer to `frame-focus` which is yet
another kettle of fish)?

​Yes, save-input-focus or save-frame-input-focus for consistency with other naming.​

​​

​​
"Manually" changing focus should be something done very rarely in Elisp,
​​
so why/when would you need to use something like `save-frame-focus`?

​Hyperbole has a feature that lets you either drag a dired item (or other item type)
to another frame (input switches to that frame) or throw the dired item to another
frame (input stays in the same frame).  The throw command calls the drag command
to reuse its logic, since it is fairly involved and doesn't make sense to duplicate,
but then needs to restore the focus to original frame.

Bob


reply via email to

[Prev in Thread] Current Thread [Next in Thread]