Lock whole screen when popup is open under GTK+.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31839 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -198,8 +198,7 @@ void wxPopupTransientWindow::PopHandlers()
|
|||||||
m_handlerPopup = NULL;
|
m_handlerPopup = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_child->HasCapture())
|
// m_child->ReleaseMouse();
|
||||||
m_child->ReleaseMouse();
|
|
||||||
m_child = NULL;
|
m_child = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -278,14 +277,30 @@ bool wxPopupTransientWindow::Show( bool show )
|
|||||||
{
|
{
|
||||||
#ifdef __WXGTK__
|
#ifdef __WXGTK__
|
||||||
if (!show)
|
if (!show)
|
||||||
|
{
|
||||||
|
gdk_pointer_ungrab( (guint32)GDK_CURRENT_TIME );
|
||||||
|
|
||||||
gtk_grab_remove( m_widget );
|
gtk_grab_remove( m_widget );
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool ret = wxPopupWindow::Show( show );
|
bool ret = wxPopupWindow::Show( show );
|
||||||
|
|
||||||
#ifdef __WXGTK__
|
#ifdef __WXGTK__
|
||||||
if (show)
|
if (show)
|
||||||
|
{
|
||||||
gtk_grab_add( m_widget );
|
gtk_grab_add( m_widget );
|
||||||
|
|
||||||
|
gdk_pointer_grab( m_widget->window, TRUE,
|
||||||
|
(GdkEventMask)
|
||||||
|
(GDK_BUTTON_PRESS_MASK |
|
||||||
|
GDK_BUTTON_RELEASE_MASK |
|
||||||
|
GDK_POINTER_MOTION_HINT_MASK |
|
||||||
|
GDK_POINTER_MOTION_MASK),
|
||||||
|
(GdkWindow *) NULL,
|
||||||
|
(GdkCursor *) NULL,
|
||||||
|
(guint32)GDK_CURRENT_TIME );
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
Reference in New Issue
Block a user