added wxWindow::NavigateIn(); provide wxGTK implementation of DoNavigateIn() working with native tab traversal

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45084 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-03-26 22:10:04 +00:00
parent 93febff2f3
commit 5644933fa6
7 changed files with 80 additions and 14 deletions

View File

@@ -3358,6 +3358,30 @@ void wxWindowGTK::DoMoveInTabOrder(wxWindow *win, MoveKind move)
wxapp_install_idle_handler();
}
bool wxWindowGTK::DoNavigateIn(int flags)
{
if ( flags & wxNavigationKeyEvent::WinChange )
{
wxFAIL_MSG( _T("not implemented") );
return false;
}
else // navigate inside the container
{
wxWindow *parent = wxGetTopLevelParent(this);
wxCHECK_MSG( parent, false, _T("every window must have a TLW parent") );
GtkDirectionType dir;
dir = flags & wxNavigationKeyEvent::IsForward ? GTK_DIR_TAB_FORWARD
: GTK_DIR_TAB_BACKWARD;
gboolean rc;
g_signal_emit_by_name(parent->m_widget, "focus", dir, &rc);
return rc == TRUE;
}
}
bool wxWindowGTK::GTKWidgetNeedsMnemonic() const
{
// none needed by default