1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-16 16:10:06 +02:00

Looks like FindFocus() on wxGTK can return NULL

This commit is contained in:
Leland Lucius 2020-03-10 12:56:43 -05:00
parent 0e42bd42b6
commit 867775ef99

View File

@ -27,11 +27,15 @@ void wxTabTraversalWrapperCharHook(wxKeyEvent &event)
event.Skip();
return;
}
focus->Navigate(
event.ShiftDown()
? wxNavigationKeyEvent::IsBackward
: wxNavigationKeyEvent::IsForward
);
// Apparently, on wxGTK, FindFocus can return NULL
if (focus)
{
focus->Navigate(
event.ShiftDown()
? wxNavigationKeyEvent::IsBackward
: wxNavigationKeyEvent::IsForward
);
}
return;
}
#endif