all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Daniel Colascione <dancol@dancol.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: luangruo@yahoo.com, 73559@debbugs.gnu.org
Subject: bug#73559: [PATCH] fix NS build focus-in event processing
Date: Mon, 30 Sep 2024 10:50:31 -0700	[thread overview]
Message-ID: <5DE09C90-164F-47B0-A752-F20C9AC82034@dancol.org> (raw)
In-Reply-To: <86bk052g5y.fsf@gnu.org>



On September 30, 2024 10:40:57 AM PDT, Eli Zaretskii <eliz@gnu.org> wrote:
>> Date: Mon, 30 Sep 2024 10:05:09 -0700
>> From: Daniel Colascione <dancol@dancol.org>
>> CC: luangruo@yahoo.com, 73559@debbugs.gnu.org
>> 
>> It's not that the NS pselect waits too long. It's that it doesn't know to wake up. The focus event is delivered to Emacs by NS as a callback. Unless that callback, one way or another, takes some action to wake up the event loop, nothing gets processed. On Windows, we drain the event queue as a side effect of the message pump, whereas on NS there doesn't seem to be a separate pump that works this way -- just a callback.
>
>What about making pselect wait on one more descriptor, to which the
>callback could then write?

That's the moral equivalent of what my patch does. My patch just uses the existing machinery for waking the main thread instead of adding a new FD.





  reply	other threads:[~2024-09-30 17:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-30  2:47 bug#73559: [PATCH] fix NS build focus-in event processing Daniel Colascione
2024-09-30  6:55 ` Stefan Kangas
2024-09-30 11:41 ` Eli Zaretskii
2024-09-30 14:20   ` Daniel Colascione
2024-09-30 15:38     ` Eli Zaretskii
2024-09-30 15:51       ` Daniel Colascione
2024-09-30 16:29         ` Eli Zaretskii
2024-09-30 17:05           ` Daniel Colascione
2024-09-30 17:40             ` Eli Zaretskii
2024-09-30 17:50               ` Daniel Colascione [this message]
2024-10-05 10:37                 ` Eli Zaretskii

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

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

  git send-email \
    --in-reply-to=5DE09C90-164F-47B0-A752-F20C9AC82034@dancol.org \
    --to=dancol@dancol.org \
    --cc=73559@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=luangruo@yahoo.com \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.