[baobab/wip/gtk4: 14/16] fix button



commit 4eadd78f9faeb221c19c0ddbf57c1c23699f8429
Author: Stefano Facchini <stefano facchini gmail com>
Date:   Sun Oct 29 15:37:33 2017 +0100

    fix button

 src/baobab-window.vala |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/src/baobab-window.vala b/src/baobab-window.vala
index d0ecae7..c95ef12 100644
--- a/src/baobab-window.vala
+++ b/src/baobab-window.vala
@@ -191,13 +191,16 @@ namespace Baobab {
             set_ui_state (home_page, false);
 
             button_press_event.connect ((event) => {
+                uint button;
+                event.get_button(out button);
                 // mouse back button
-                if (event.button == 8) {
+                if (button == 8) {
                     lookup_action ("show-home-page").activate (null);
                     return Gdk.EVENT_STOP;
                 }
                 return Gdk.EVENT_PROPAGATE;
             });
+            print("DONE\n");
         }
 
         void on_show_home_page_activate () {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]