From 06911c611ad320fc167cc9ff777fb678dc7c8ce7 Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Mon, 18 May 2015 17:43:32 +0800 Subject: [PATCH] src/Builder4/MainWindow.bjs src/Builder4/MainWindow.vala --- src/Builder4/MainWindow.bjs | 2 +- src/Builder4/MainWindow.vala | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/Builder4/MainWindow.bjs b/src/Builder4/MainWindow.bjs index 92392c05d..4024222cb 100644 --- a/src/Builder4/MainWindow.bjs +++ b/src/Builder4/MainWindow.bjs @@ -634,7 +634,7 @@ }, { "listeners" : { - "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n if (this.popup.active) {\n this.popup.active = false;\n this.popup.el.hide();\n return true;\n }\n this.popup.show(this.notices, this.el);\n return true;\n}" + "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n \n if (_this.statusbar_errors.popup != null && _this.statusbar_errors.popup.active) {\n _this.statusbar_errors.popup.active = false;\n _this.statusbar_errors.popup.el.hide();\n }\n if (_this.statusbar_depricated.popup != null && _this.statusbar_depricated.popup.active) {\n _this.statusbar_depricated.popup.active = false;\n _this.statusbar_depricated.popup.el.hide();\n }\n \n if (this.popup.active) {\n this.popup.active = false;\n this.popup.el.hide();\n return true;\n }\n this.popup.show(this.notices, this.el);\n return true;\n}" }, "bool always_show_image" : true, "id" : "statusbar_warnings", diff --git a/src/Builder4/MainWindow.vala b/src/Builder4/MainWindow.vala index fbf0af9fc..437037aa9 100644 --- a/src/Builder4/MainWindow.vala +++ b/src/Builder4/MainWindow.vala @@ -2391,6 +2391,16 @@ public class Xcls_MainWindow : Object this.popup = new Xcls_ValaCompileErrors(); this.popup.window = _this; } + + if (_this.statusbar_errors.popup != null && _this.statusbar_errors.popup.active) { + _this.statusbar_errors.popup.active = false; + _this.statusbar_errors.popup.el.hide(); + } + if (_this.statusbar_depricated.popup != null && _this.statusbar_depricated.popup.active) { + _this.statusbar_depricated.popup.active = false; + _this.statusbar_depricated.popup.el.hide(); + } + if (this.popup.active) { this.popup.active = false; this.popup.el.hide(); -- 2.39.2