NewBranch.bjs
authorAlan Knowles <alan@roojs.com>
Thu, 21 Mar 2019 06:31:11 +0000 (14:31 +0800)
committerAlan Knowles <alan@roojs.com>
Thu, 21 Mar 2019 06:31:11 +0000 (14:31 +0800)
NewBranch.vala

NewBranch.bjs
NewBranch.vala

index bab8cf0..f3946f3 100644 (file)
            },
            "label" : "Commit Changes",
            "id" : "createbtn",
+           "| void updateState" : "() {\n\n\tvar msg = _this.commit_message.el.getText();\n\t\n\tif (msg == \"\") {\n\t\tthis.el.set_sensitive(false);\n\t\treturn;\n\t}\n \n\tthis.el.set_sensitive(true);\n \n}\n",
            "* init" : "{\n   this.el.get_style_context().add_class(\"suggested-action\");\n}\n",
            "xtype" : "Button",
            "* pack" : "attach_defaults,0,5,2,3",
-           "$ xns" : "Gtk",
-           "| return_type XXXX" : "() {\n\n\tvar msg = _this.commit_message.el.getText();\n\t\n\tif (msg == \"\") {\n\t\tthis.el.set_sensitive(false);\n\t\treturn;\n\t}\n \n\tthis.el.set_sensitive(true);\n \n}\n"
+           "$ xns" : "Gtk"
           }
          ]
         },
index 8599788..ced3872 100644 (file)
@@ -2419,7 +2419,7 @@ public class NewBranch : Object
         }
 
         // user defined functions
-        public return_type XXXX () {
+        public void updateState () {
         
                var msg = _this.commit_message.el.getText();