From 5b98e4b2fa57fce5bdde012cc77debdd84cfda15 Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Thu, 21 Mar 2019 14:30:51 +0800 Subject: [PATCH] NewBranch.bjs NewBranch.vala --- NewBranch.bjs | 2 +- NewBranch.vala | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/NewBranch.bjs b/NewBranch.bjs index 5c39d8f6..bab8cf01 100644 --- a/NewBranch.bjs +++ b/NewBranch.bjs @@ -555,7 +555,7 @@ "xtype" : "Button", "* pack" : "attach_defaults,0,5,2,3", "$ xns" : "Gtk", - "| return_type XXXX" : "() {\n\n\tvar ticket_id = _this.ticketsel.selectedTicketId();\n\t\n\tif (ticket_id == \"\") {\n\t\tthis.el.set_sensitive(false);\n\t\treturn;\n\t}\n \n\tthis.el.set_sensitive(true);\n \n}\n" + "| 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" } ] }, diff --git a/NewBranch.vala b/NewBranch.vala index bbdf7867..8599788a 100644 --- a/NewBranch.vala +++ b/NewBranch.vala @@ -2421,9 +2421,9 @@ public class NewBranch : Object // user defined functions public return_type XXXX () { - var ticket_id = _this.ticketsel.selectedTicketId(); + var msg = _this.commit_message.el.getText(); - if (ticket_id == "") { + if (msg == "") { this.el.set_sensitive(false); return; } -- 2.39.2