unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* We should decouple focus and frame switching
@ 2018-06-10 18:07 Daniel Colascione
  2018-06-10 23:16 ` John Wiegley
  2018-06-11  2:35 ` Eli Zaretskii
  0 siblings, 2 replies; 13+ messages in thread
From: Daniel Colascione @ 2018-06-10 18:07 UTC (permalink / raw)
  To: Emacs developers

Focus-in and focus-out don't do a good job right now of reflecting 
actual window system focus state, and that's in part due to the core 
considering frame switch evidence of a focus change and running the 
focus-in hooks in response. More than one frame can have window system 
focus at a time when we have multiple terminals, and even on a single 
terminal, internal frame switching for processing mouse wheel events and 
such shouldn't change the reported window system focus state.

How about this? We'll add a frame-focused-p function that returns nil, 
t, or 'unknown, and wire up focus-in-hook and focus-out-hook to run only 
when we actually observe a window system focus change, letting the frame 
switch stuff run completely independently. This way, we'll be able to 
write lisp (as I've been trying to do) that reflects the real window 
system focus.

Sound good?



^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2018-06-13  3:50 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-10 18:07 We should decouple focus and frame switching Daniel Colascione
2018-06-10 23:16 ` John Wiegley
2018-06-10 23:28   ` dancol
2018-06-11  0:04     ` T.V Raman
2018-06-11  0:20       ` dancol
2018-06-11  1:07         ` T.V Raman
2018-06-11 13:00           ` Clément Pit-Claudel
2018-06-11 15:17         ` Stefan Monnier
2018-06-11 15:56         ` Eli Zaretskii
2018-06-13  3:34     ` Michael Heerdegen
2018-06-13  3:50       ` dancol
2018-06-11  2:35 ` Eli Zaretskii
2018-06-11  3:24   ` dancol

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).