diff options
author | ZenWalker <[email protected]> | 2017-03-07 20:52:06 +0100 |
---|---|---|
committer | ZenWalker <[email protected]> | 2017-03-07 20:55:07 +0100 |
commit | f36575da68c26104894173db1271c65f821be5de (patch) | |
tree | 611b760c3c5826cf9ef8b213fe66a2d23471433b | |
parent | 2ad12237699e722bc996c3af1ac23e1db0093b85 (diff) | |
download | pluma-f36575da68c26104894173db1271c65f821be5de.tar.bz2 pluma-f36575da68c26104894173db1271c65f821be5de.tar.xz |
Fix: the tab closes unexpectedly with middle click under line numbers
Fixes #215
-rw-r--r-- | pluma/pluma-view.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/pluma/pluma-view.c b/pluma/pluma-view.c index b73315e6..707656a3 100644 --- a/pluma/pluma-view.c +++ b/pluma/pluma-view.c @@ -1988,13 +1988,16 @@ static gboolean pluma_view_button_press_event (GtkWidget *widget, GdkEventButton *event) { if ((event->type == GDK_BUTTON_PRESS) && - (event->button == 3) && (event->window == gtk_text_view_get_window (GTK_TEXT_VIEW (widget), GTK_TEXT_WINDOW_LEFT))) { - show_line_numbers_menu (widget, event); - - return TRUE; + if (event->button == 3) + { + show_line_numbers_menu (widget, event); + return TRUE; + } + else if (event->button == 2) + return TRUE; } return GTK_WIDGET_CLASS (pluma_view_parent_class)->button_press_event (widget, event); |