From: YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
To: Po Lu <luangruo@yahoo.com>
Cc: emacs-devel@gnu.org
Subject: Re: master 2021835326 2/3: Implement `return-frame' for DND on NS
Date: Thu, 26 Jan 2023 20:29:39 +0900 [thread overview]
Message-ID: <wly1ppy1ng.wl-mituharu@math.s.chiba-u.ac.jp> (raw)
In-Reply-To: <87y1yh97g4.fsf@yahoo.com>
On Tue, 31 May 2022 22:07:23 +0900,
Po Lu wrote:
>
> > + /* FIXME: there must be a better way to leave the event loop. */
> > + [NSException raise: @""
> > + format: @"Must return DND frame"];
> > +}
> > +#endif
>
> This works (and there's nothing in the documentation forbidding it), but
> prints an ugly warning message to stdout every time the exception is
> raised. Does anyone know of a better way to stop an NS drag-and-drop
> operation inside one of the drag source callbacks?
Posting ESC KeyDown event seems to work, as long as I tested with
Emacs 29-based Mac port (in development).
BTW, I think safe_call/redisplay in -[EmacsView draggingUpdated:] is
unsafe in some situations. This method is called from the main thread
in the context of `select' emulation if the dragging is originated
from another application. Because `thread_select' may cause thread
switching if we have multiple Lisp threads, Lisp evaluation in another
thread might be in progress while the main thread is waiting for the
completion of the `select' emulation.
YAMAMOTO Mitsuharu
mituharu@math.s.chiba-u.ac.jp
next prev parent reply other threads:[~2023-01-26 11:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <165399160266.27129.5728276928017774382@vcs2.savannah.gnu.org>
[not found] ` <20220531100643.37E30C0C1B3@vcs2.savannah.gnu.org>
2022-05-31 13:07 ` master 2021835326 2/3: Implement `return-frame' for DND on NS Po Lu
2023-01-26 11:29 ` YAMAMOTO Mitsuharu [this message]
2023-01-26 11:43 ` Po Lu
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=wly1ppy1ng.wl-mituharu@math.s.chiba-u.ac.jp \
--to=mituharu@math.s.chiba-u.ac.jp \
--cc=emacs-devel@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.