diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index e85cc90c77..9ace53a97c 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -1105,7 +1105,7 @@ gtk_window_key_press_callback( GtkWidget *WXUNUSED(widget), break; } - if (ancestor->IsTopLevel()) + if (ancestor->IsTopNavigationDomain()) break; ancestor = ancestor->GetParent(); } diff --git a/src/msw/evtloop.cpp b/src/msw/evtloop.cpp index 1d5ccc7737..cb2bae0d5f 100644 --- a/src/msw/evtloop.cpp +++ b/src/msw/evtloop.cpp @@ -137,7 +137,7 @@ bool wxGUIEventLoop::PreProcessMessage(WXMSG *msg) // stop at first top level window, i.e. don't try to process the key // strokes originating in a dialog using the accelerators of the parent // frame - this doesn't make much sense - if ( wnd->IsTopLevel() ) + if ( wnd->IsTopNavigationDomain() ) break; } @@ -151,7 +151,7 @@ bool wxGUIEventLoop::PreProcessMessage(WXMSG *msg) // if we don't do this, pressing ESC on a modal dialog shown as child // of a modal dialog with wxID_CANCEL will cause the parent dialog to // be closed, for example - if ( wnd->IsTopLevel() ) + if ( wnd->IsTopNavigationDomain() ) break; } diff --git a/src/osx/window_osx.cpp b/src/osx/window_osx.cpp index 67a96cce70..4e027720e7 100644 --- a/src/osx/window_osx.cpp +++ b/src/osx/window_osx.cpp @@ -2761,7 +2761,7 @@ bool wxWindowMac::OSXHandleKeyEvent( wxKeyEvent& event ) break; } - if (ancestor->IsTopLevel()) + if (ancestor->IsTopNavigationDomain()) break; ancestor = ancestor->GetParent();