diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2016-12-28 01:02:33 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-01-09 16:40:19 +0000 |
commit | f1b786bdd2576f584c62bfa797d3849eb5330c2c (patch) | |
tree | 8e2c168e987bb70f22ab375bcfa6072b85aef77e /vcl | |
parent | 97b9f00e3a443f636416d047e7fdcb7a91fac937 (diff) |
tdf#104944 gtk3: Ignore mouse up event if the wrong frame
Change-Id: I3d0aad6d2b434866df9110d3b8493fec2d2c94fe
Reviewed-on: https://gerrit.libreoffice.org/32465
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
(cherry picked from commit 23a13694a5a70098b5ecd58b99d99618111f3ea5)
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/unx/gtk3/gtk3gtkframe.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx index ab1026072936..56a74ac81723 100644 --- a/vcl/unx/gtk3/gtk3gtkframe.cxx +++ b/vcl/unx/gtk3/gtk3gtkframe.cxx @@ -2610,11 +2610,12 @@ gboolean GtkSalFrame::signalButton( GtkWidget*, GdkEventButton* pEvent, gpointer vcl::DeletionListener aDel( pThis ); - if (pEvent->type == GDK_BUTTON_PRESS && pThis->isFloatGrabWindow()) + if (pThis->isFloatGrabWindow() && pEvent->window != widget_get_window(pThis->getMouseEventWidget())) { - bool bClosePopups = (pEvent->window != widget_get_window(pThis->getMouseEventWidget())); - if (bClosePopups) + if (pEvent->type == GDK_BUTTON_PRESS) pThis->closePopup(); + else if (pEvent->type == GDK_BUTTON_RELEASE) + return true; } if (!aDel.isDeleted()) |