@@ -23,7 +23,7 @@ public class ProgressWindow : Window {
2323 private Revealer revealer2;
2424
2525 private Button btn_cancel;
26- private Button btn_show_files ;
26+ private Button btn_launch_now ;
2727 private Button btn_quit;
2828
2929 private Pid child_pid;
@@ -85,9 +85,10 @@ public class ProgressWindow : Window {
8585 btn_quit. clicked. connect(Gtk . main_quit);
8686 btn_quit. set_visible(false );
8787
88- btn_show_files = builder. get_object(" btn_show_files" ) as Button ;
89- btn_show_files. clicked. connect(this . show_files);
90- btn_show_files. set_visible(false );
88+ btn_launch_now = builder. get_object(" btn_launch_now" ) as Button ;
89+ btn_launch_now. clicked. connect(this . show_files);
90+ btn_launch_now. set_visible(false );
91+ btn_launch_now. set_sensitive(false );
9192
9293 this . files_to_be_updated = files_to_be_updated;
9394 this . file_name = file_name;
@@ -136,16 +137,15 @@ public class ProgressWindow : Window {
136137 return this . process_error (channel, condition, " stderr" );
137138 });
138139
139- ChildWatch . add (child_pid, (pid, status) = > {
140- // Triggered when the child indicated by child_pid exits
141- Process . close_pid (pid);
142-
140+ ChildWatch . add (child_pid, (pid, status) = > {
141+ // Triggered when the child indicated by child_pid exits
142+ Process . close_pid(pid);
143+ btn_launch_now . set_sensitive( true );
143144 });
144145
145146 } catch (SpawnError e) {
146147 action_label. label = " Error: " + e. message;
147148 }
148-
149149 }
150150
151151 /* Handle output pipe */
@@ -187,7 +187,7 @@ public class ProgressWindow : Window {
187187revealer2. set_reveal_child (true );
188188 icon_image. icon_name= " emblem-ok-symbolic" ;
189189 Posix . system(" chmod 0755 " + result_file_name); // Because the CLI does not reliably do it (FIXME)
190- btn_show_files . set_visible(true );
190+ btn_launch_now . set_visible(true );
191191 }
192192
193193 if (line. contains(" Cannot" ) || line. contains(" Error" )) {
0 commit comments