Let windows with wxWANTS_CHARS have TAB presses under Mac
This notably fixes the use of TAB in wxStyledTextCtrl, where it's
supposed to be handled by the control itself and not as a navigation
key, but is more general than this.
Fixes a regression from 8bca6deda3
.
Closes #17999.
This commit is contained in:
@@ -3552,8 +3552,9 @@ bool wxWidgetCocoaImpl::DoHandleCharEvent(NSEvent *event, NSString *text)
|
|||||||
|
|
||||||
bool wxWidgetCocoaImpl::ShouldHandleKeyNavigation(const wxKeyEvent &WXUNUSED(event)) const
|
bool wxWidgetCocoaImpl::ShouldHandleKeyNavigation(const wxKeyEvent &WXUNUSED(event)) const
|
||||||
{
|
{
|
||||||
// Only controls that intercept tabs for different behavior should return false (ie wxTE_PROCESS_TAB)
|
// If the window wants to have all keys, let it have it and don't process
|
||||||
return true;
|
// TAB as key navigation event.
|
||||||
|
return !m_wxPeer->HasFlag(wxWANTS_CHARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxWidgetCocoaImpl::DoHandleKeyNavigation(const wxKeyEvent &event)
|
bool wxWidgetCocoaImpl::DoHandleKeyNavigation(const wxKeyEvent &event)
|
||||||
|
Reference in New Issue
Block a user