diff --git a/js/ui/main.js b/js/ui/main.js index 882e34b2e..5b21ea41b 100644 --- a/js/ui/main.js +++ b/js/ui/main.js @@ -32,10 +32,12 @@ function start() { // Make sure not more than one run dialog is shown. if (!run_dialog) { run_dialog = new RunDialog.RunDialog(); - run_dialog.on_run = run_dialog.on_cancel = function() { + let handler = function() { run_dialog.destroy(); run_dialog = null; }; + run_dialog.connect('run', handler); + run_dialog.connect('cancel', handler); run_dialog.show(); } });