Skip to content

Commit 02dd55e

Browse files
authored
Multi line text view key handling: add check for first responder (#2217)
1 parent 43f8b2e commit 02dd55e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/react-native/Libraries/Text/TextInput/Multiline/RCTUITextView.mm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ - (void)deleteBackward {
587587
}
588588
#else // [macOS
589589
- (BOOL)performKeyEquivalent:(NSEvent *)event {
590-
if (!self.hasMarkedText && ![self.textInputDelegate textInputShouldHandleKeyEvent:event]) {
590+
if (self.window.firstResponder == self && !self.hasMarkedText && ![self.textInputDelegate textInputShouldHandleKeyEvent:event]) {
591591
return YES;
592592
}
593593

0 commit comments

Comments
 (0)