Skip to content

[0.74] Multiline TextInput key handling: add check for first responder - #2216

Merged
Saad Najmi (Saadnajmi) merged 1 commit into
0.74-stablefrom
nakambo/multiline-textview-key-equivalent-fix-74
Oct 9, 2024
Merged

[0.74] Multiline TextInput key handling: add check for first responder#2216
Saad Najmi (Saadnajmi) merged 1 commit into
0.74-stablefrom
nakambo/multiline-textview-key-equivalent-fix-74

Conversation

@nakambo

Copy link
Copy Markdown
Collaborator

Bring over #2215 to 0.74

performKeyEquivalent is [documented](https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/EventOverview/EventArchitecture/EventArchitecture.html#//apple_ref/doc/uid/10000060i-CH3-SW10) to be called even if a view isn't first responder (this is for example how "Enter" binds to the default button on a dialog, for example -- the default button doesn't need to be focused to respond to Enter), but since we override performKeyEquivalent to properly support certain keyboard shortcuts (like noted in #1867), the previous assumption on the actual use of performKeyEquivalent no longer holds -- it's *only* for keystrokes sent in focused state, so add that check.
@Saadnajmi
Saad Najmi (Saadnajmi) merged commit 8ea714b into 0.74-stableOct 9, 2024
@Saadnajmi
Saad Najmi (Saadnajmi) deleted the nakambo/multiline-textview-key-equivalent-fix-74 branch October 9, 2024 03:24
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@nakambo@Saadnajmi