From: Václav Slavík Date: Sat, 14 Aug 2004 22:54:11 +0000 (+0000) Subject: reverted accidentally committed changes in previous revision X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/61721d057edd248006baa0c02592f4d7f5d45980 reverted accidentally committed changes in previous revision git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28786 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index 14a770ef10..07ff8e6952 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -251,16 +251,6 @@ static bool g_activeFrameLostFocus = FALSE; // yet, defer setting the focus to idle time. wxWindowGTK *g_delayedFocus = (wxWindowGTK*) NULL; -// When GTK+ focus_in/out signal is being processed, we shouldn't do -// any focus changes -static bool gs_inFocusSignalHandler = false; - -struct InFocusHandlerLock -{ - InFocusHandlerLock() { gs_inFocusSignalHandler = true; } - ~InFocusHandlerLock() { gs_inFocusSignalHandler = false; } -}; - // if we detect that the app has got/lost the focus, we set this variable to // either TRUE or FALSE and an activate event will be sent during the next // OnIdle() call and it is reset to -1: this value means that we shouldn't @@ -1973,8 +1963,6 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, GdkEvent *WXUNUSED(event), wxWindow *win ) { - InFocusHandlerLock flock; - DEBUG_MAIN_THREAD if (g_isIdle) @@ -2069,8 +2057,6 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, static gint gtk_window_focus_out_callback( GtkWidget *widget, GdkEventFocus *gdk_event, wxWindowGTK *win ) { DEBUG_MAIN_THREAD - - InFocusHandlerLock flock; if (g_isIdle) wxapp_install_idle_handler(); @@ -3622,14 +3608,6 @@ void wxWindowGTK::SetFocus() return; } - if (gs_inFocusSignalHandler) - { - wxLogTrace(TRACE_FOCUS, - _T("in focus handler, delaying SetFocus(%p)"), this); - g_delayedFocus = this; - return; - } - if (m_wxwindow) { if (!GTK_WIDGET_HAS_FOCUS (m_wxwindow)) diff --git a/src/gtk1/window.cpp b/src/gtk1/window.cpp index 14a770ef10..07ff8e6952 100644 --- a/src/gtk1/window.cpp +++ b/src/gtk1/window.cpp @@ -251,16 +251,6 @@ static bool g_activeFrameLostFocus = FALSE; // yet, defer setting the focus to idle time. wxWindowGTK *g_delayedFocus = (wxWindowGTK*) NULL; -// When GTK+ focus_in/out signal is being processed, we shouldn't do -// any focus changes -static bool gs_inFocusSignalHandler = false; - -struct InFocusHandlerLock -{ - InFocusHandlerLock() { gs_inFocusSignalHandler = true; } - ~InFocusHandlerLock() { gs_inFocusSignalHandler = false; } -}; - // if we detect that the app has got/lost the focus, we set this variable to // either TRUE or FALSE and an activate event will be sent during the next // OnIdle() call and it is reset to -1: this value means that we shouldn't @@ -1973,8 +1963,6 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, GdkEvent *WXUNUSED(event), wxWindow *win ) { - InFocusHandlerLock flock; - DEBUG_MAIN_THREAD if (g_isIdle) @@ -2069,8 +2057,6 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, static gint gtk_window_focus_out_callback( GtkWidget *widget, GdkEventFocus *gdk_event, wxWindowGTK *win ) { DEBUG_MAIN_THREAD - - InFocusHandlerLock flock; if (g_isIdle) wxapp_install_idle_handler(); @@ -3622,14 +3608,6 @@ void wxWindowGTK::SetFocus() return; } - if (gs_inFocusSignalHandler) - { - wxLogTrace(TRACE_FOCUS, - _T("in focus handler, delaying SetFocus(%p)"), this); - g_delayedFocus = this; - return; - } - if (m_wxwindow) { if (!GTK_WIDGET_HAS_FOCUS (m_wxwindow))