[vim/vim] perf(gtk3-dialog): normalize FocusGained (PR #20780)

2 views
Skip to first unread message

dezza

unread,
Jul 16, 2026, 6:11:42 PM (10 hours ago) Jul 16
to vim/vim, Subscribed

gtk3 dialogs can trigger FocusGained while a dialog is active or- immediately after it closes in a loop.

Previously:

  • Wayland: queued FocusGained events gives multiple dialogs.
  • X11: Close triggers focus_in_event() and FocusGained loop.

Track active GUI dialogs for future use and suppress dialog-generated focus events while a dialog is active.

On X11, also ignore the restoring focus_in_event() caused by closing a dialog.

This normalizes the behaviour between Wayland and X11 while matching terminal Vim, where only a single dialog can be active.


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/20780

Commit Summary

  • 35e02d7 perf(gtk3-dialog): normalize FocusGained

File Changes

(4 files)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/20780@github.com>

dezza

unread,
Jul 16, 2026, 6:28:25 PM (10 hours ago) Jul 16
to vim/vim, Subscribed
dezza left a comment (vim/vim#20780)

draft because .. Seeing if I can get a unittest working by adding a lightweight WM for x11 where the largest chance is. Makes sense to unit-test this.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/20780/c4997211533@github.com>

Reply all
Reply to author
Forward
0 new messages