unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Third <alan@idiocy.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: Sean Farley <sean@farley.io>, 47731@debbugs.gnu.org
Subject: bug#47731: 28.0.50; Switching frame via keyboard does not fire focus change event
Date: Thu, 6 May 2021 18:57:53 +0100	[thread overview]
Message-ID: <YJQuIdNolFbxzecr@idiocy.org> (raw)
In-Reply-To: <875yzwyypp.fsf@gnus.org>

On Thu, May 06, 2021 at 11:54:10AM +0200, Lars Ingebrigtsen wrote:
> Sean Farley <sean@farley.io> writes:
> 
> > Here is some testing code:
> > (defun test--focus-out ()
> >   (message "FOCUS TEST"))
> >
> > (add-function :after after-focus-change-function #'test--focus-out)
> > (make-frame)
> >
> > On macOS, this code runs fine if you click on the other frame. But if
> > using the keyboard shortcut Command-` the event doesn't fire. It seems
> > to be some interaction in the keydown event function where emacs_event
> > is cleared before the call to windowDidBecomeKey.
> 
> I haven't tested the recipe, but perhaps Alan has some comments here
> (added to the CCs).

Interestingly the NS port only generates Emacs events for things that
happen within the NS run loop, which excludes many things that are
initiated by Emacs itself.

I'm not sure how to fix this as I'm not sure why it's set up this way.
-- 
Alan Third





  reply	other threads:[~2021-05-06 17:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-12 16:17 bug#47731: 28.0.50; Switching frame via keyboard does not fire focus change event Sean Farley via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-05-06  9:54 ` Lars Ingebrigtsen
2021-05-06 17:57   ` Alan Third [this message]
2021-08-29  3:23     ` Sean Farley via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-08-29  9:38       ` Alan Third

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YJQuIdNolFbxzecr@idiocy.org \
    --to=alan@idiocy.org \
    --cc=47731@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=sean@farley.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).