X-Git-Url: http://git.roojs.org/?p=gitlive;a=blobdiff_plain;f=NewBranch.vala;fp=NewBranch.vala;h=bd6fedd2a5612630f0148228833eb03ac34d83fe;hp=03e56b91e7b42d3292f44002709767f432b0e26d;hb=3ca10752a9d585c7d1f731322f9e1174493cc9e0;hpb=87963ea388fba20b1d03d7fb01df3d4886fdccbb diff --git a/NewBranch.vala b/NewBranch.vala index 03e56b91..bd6fedd2 100644 --- a/NewBranch.vala +++ b/NewBranch.vala @@ -37,7 +37,7 @@ public class NewBranch : Object // my vars (dec) this.repo = null; - this.running = true; + this.running = false; this.queue = null; // set gobject values @@ -60,9 +60,7 @@ public class NewBranch : Object GLib.debug("got %d", (int) response_id); - - - + // have they selected a ticket.. @@ -72,20 +70,15 @@ public class NewBranch : Object // -- each repo would have their active ticket (only one per repo) // -- so we could just store that in there // -- initial load can check the contents of the ticket files on first scan. - var ticket_id = _this.ticketsel.selectedTicketId(); - - if (ticket_id == "") { - _this.ticketsel.el.get_child().get_style_context().add_class("warning"); - return; - } - - + + if (response_id < 1) { _this.el.hide(); this.running = false; return; } + var ticket_id = _this.ticketsel.selectedTicketId(); if (this.repo != null) { var bn = _this.name.el.get_text(); @@ -99,7 +92,7 @@ public class NewBranch : Object } } - + this.running = false; @@ -722,7 +715,16 @@ public class NewBranch : Object //listeners this.el.clicked.connect( () => { + GLib.debug("fire response = 1"); + + var ticket_id = _this.ticketsel.selectedTicketId(); + + if (ticket_id == "") { + _this.ticketsel.el.get_child().get_style_context().add_class("warning"); + return; + } + _this.el.response(1); }); }