RepoStatusPopover.bjs
authorAlan Knowles <alan@roojs.com>
Wed, 19 Dec 2018 05:48:48 +0000 (13:48 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 19 Dec 2018 05:48:48 +0000 (13:48 +0800)
RepoStatusPopover.vala

RepoStatusPopover.bjs
RepoStatusPopover.vala

index f34844e..049ce31 100644 (file)
@@ -53,7 +53,7 @@
           },
           {
            "listeners" : {
-            "button_press_event" : "() => {\n   _this.repo.git({ \"commit\" , \"-a\" ,\"-m\", \"Uncommited changes synced\" });\n   _this.repo.push();\n   _this.repo.loadStatus();\n   \n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    \n   _this.el.hide();\n   Clones.singleton().reposStore.load();\n   \n    return false;\n}"
+            "clicked" : "() => {\n   _this.repo.git({ \"commit\" , \"-a\" ,\"-m\", \"Uncommited changes synced\" });\n   _this.repo.push();\n   _this.repo.loadStatus();\n   \n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    \n   _this.el.hide();\n   Clones.singleton().reposStore.load();\n   \n    return false;\n}"
            },
            "label" : "Commit Changes",
            "* ctor" : "new Gtk.ToolButton(new Gtk.Image.from_icon_name (\"gtk-save\", Gtk.IconSize.SMALL_TOOLBAR), null);",
@@ -65,7 +65,7 @@
           },
           {
            "listeners" : {
-            "button_press_event" : "() => {\n  \n   \n   GitMonitor.gitmonitor.stop();\n   _this.repo.git({ \"reset\" , \"--hard\" });\n   _this.repo.loadStatus();\n   GitMonitor.gitmonitor.start();\n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    Clones.singleton().reposStore.load();\n  \n   _this.el.hide();\n    return false;\n}"
+            "clicked" : "() => {\n  \n   \n   GitMonitor.gitmonitor.stop();\n   _this.repo.git({ \"reset\" , \"--hard\" });\n   _this.repo.loadStatus();\n   GitMonitor.gitmonitor.start();\n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    Clones.singleton().reposStore.load();\n  \n   _this.el.hide();\n    return false;\n}"
            },
            "label" : "Reset / clear changes",
            "* ctor" : "new Gtk.ToolButton(new Gtk.Image.from_icon_name (\"gtk-revert-to-saved\", Gtk.IconSize.SMALL_TOOLBAR), null);",
@@ -77,7 +77,7 @@
           },
           {
            "listeners" : {
-            "button_press_event" : "() => {\n  \n   \n   GitMonitor.gitmonitor.stop();\n   _this.repo.git({ \"pull\" , \"--all\" });\n   _this.repo.loadStatus();\n   GitMonitor.gitmonitor.start();\n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    Clones.singleton().reposStore.load();\n  \n   _this.el.hide();\n    return false;\n}"
+            "clicked" : "() => {\n  \n   \n   GitMonitor.gitmonitor.stop();\n   _this.repo.git({ \"pull\" , \"--all\" });\n   _this.repo.loadStatus();\n   GitMonitor.gitmonitor.start();\n    _this.diff_view.el.get_buffer().set_text(_this.repo.git_diff);\n    _this.status_view.el.get_buffer().set_text(_this.repo.git_status);\n    Clones.singleton().reposStore.load();\n  \n   _this.el.hide();\n    return false;\n}"
            },
            "label" : "Pull updates",
            "* ctor" : "new Gtk.ToolButton(new Gtk.Image.from_icon_name (\"gtk-goto-bottom\", Gtk.IconSize.SMALL_TOOLBAR), null);",
          "items" : [
           {
            "listeners" : {
-            "button_press_event" : "() => {\n   var oldq = new Gee.ArrayList<GitMonitorQueue>();  \n\n\tClones.singleton().el.response(-1);\n\tNewBranch.singleton().show(_this.repo, oldq);\n\n    return false;\n}"
+            "clicked" : "() => {\n   var oldq = new Gee.ArrayList<GitMonitorQueue>();  \n\n\tClones.singleton().el.response(-1);\n\tNewBranch.singleton().show(_this.repo, oldq);\n\n    return false;\n}"
            },
            "label" : "Create Branch / Start ticket",
            "* ctor" : "new Gtk.ToolButton(new Gtk.Image.from_icon_name (\"gtk-add\", Gtk.IconSize.SMALL_TOOLBAR), null);",
           },
           {
            "listeners" : {
-            "button_press_event" : "() => {\n  \n\n\n      Clones.singleton().el.response(-1);\n  \n   _this.el.hide();\n   Ticket.singleton().show( _this.repo);\n   \n    return false;\n}"
+            "clicked" : "() => {\n  \n\n\n      Clones.singleton().el.response(-1);\n  \n   _this.el.hide();\n   Ticket.singleton().show( _this.repo);\n   \n    return false;\n}"
            },
            "label" : "Create Ticket",
            "* ctor" : "new Gtk.ToolButton(new Gtk.Image.from_icon_name (\"gtk-new\", Gtk.IconSize.SMALL_TOOLBAR), null);",
index 1975bfc..c8974e3 100644 (file)
@@ -241,7 +241,7 @@ public class RepoStatusPopover : Object
             this.el.is_important = true;
 
             //listeners
-            this.el.button_press_event.connect( () => {
+            this.el.clicked.connect( () => {
                _this.repo.git({ "commit" , "-a" ,"-m", "Uncommited changes synced" });
                _this.repo.push();
                _this.repo.loadStatus();
@@ -281,7 +281,7 @@ public class RepoStatusPopover : Object
             this.el.is_important = true;
 
             //listeners
-            this.el.button_press_event.connect( () => {
+            this.el.clicked.connect( () => {
               
                
                GitMonitor.gitmonitor.stop();
@@ -322,7 +322,7 @@ public class RepoStatusPopover : Object
             this.el.is_important = true;
 
             //listeners
-            this.el.button_press_event.connect( () => {
+            this.el.clicked.connect( () => {
               
                
                GitMonitor.gitmonitor.stop();
@@ -659,7 +659,7 @@ public class RepoStatusPopover : Object
             this.el.is_important = true;
 
             //listeners
-            this.el.button_press_event.connect( () => {
+            this.el.clicked.connect( () => {
                var oldq = new Gee.ArrayList<GitMonitorQueue>();  
             
                Clones.singleton().el.response(-1);
@@ -729,7 +729,7 @@ public class RepoStatusPopover : Object
             this.el.is_important = true;
 
             //listeners
-            this.el.button_press_event.connect( () => {
+            this.el.clicked.connect( () => {