Patchwork [bitbake-devel] hob: remove parsing warnings when machine is changed

login
register
mail settings
Submitter Cristiana Voicu
Date Feb. 4, 2013, 2:56 p.m.
Message ID <1359989760-16394-1-git-send-email-cristiana.voicu@intel.com>
Download mbox | patch
Permalink /patch/44013/
State New
Headers show

Comments

Cristiana Voicu - Feb. 4, 2013, 2:56 p.m.
When the machine is changed, the warnings list is emptied and the warnings
bar is hidden.

[YOCTO #3830]
Signed-off-by: Cristiana Voicu <cristiana.voicu@intel.com>
---
 bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py |    7 +++++++
 1 file changed, 7 insertions(+)

Patch

diff --git a/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py b/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
index df7a017..956f5ce 100644
--- a/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
+++ b/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
@@ -173,6 +173,11 @@  class ImageConfigurationPage (HobPage):
 
         return warnings_bar
 
+    def disable_warnings_bar(self):
+        if self.builder.parsing_warnings:
+            self.warnings_bar.hide_all()
+            self.builder.parsing_warnings = []
+
     def create_config_machine(self):
         self.machine_title = gtk.Label()
         self.machine_title.set_alignment(0.0, 0.5)
@@ -319,6 +324,7 @@  class ImageConfigurationPage (HobPage):
         self.builder.populate_recipe_package_info_async()
 
     def update_machine_combo(self):
+        self.disable_warnings_bar()
         all_machines = [self.__dummy_machine__] + self.builder.parameters.all_machines
 
         model = self.machine_combo.get_model()
@@ -328,6 +334,7 @@  class ImageConfigurationPage (HobPage):
         self.machine_combo.set_active(0)
 
     def switch_machine_combo(self):
+        self.disable_warnings_bar()
         self.machine_combo_changed_by_manual = False
         model = self.machine_combo.get_model()
         active = 0