summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r--bitbake/lib/bb/ui/hob.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/bitbake/lib/bb/ui/hob.py b/bitbake/lib/bb/ui/hob.py
index fca41e44dc..7647d2139f 100644
--- a/bitbake/lib/bb/ui/hob.py
+++ b/bitbake/lib/bb/ui/hob.py
@@ -50,7 +50,6 @@ class MainWindow (gtk.Window):
50 self.model = taskmodel 50 self.model = taskmodel
51 self.model.connect("tasklist-populated", self.update_model) 51 self.model.connect("tasklist-populated", self.update_model)
52 self.model.connect("image-changed", self.image_changed_string_cb) 52 self.model.connect("image-changed", self.image_changed_string_cb)
53 self.curr_image_path = None
54 self.handler = handler 53 self.handler = handler
55 self.configurator = configurator 54 self.configurator = configurator
56 self.prefs = prefs 55 self.prefs = prefs
@@ -133,12 +132,13 @@ class MainWindow (gtk.Window):
133 if it: 132 if it:
134 path = model.get_path(it) 133 path = model.get_path(it)
135 # Firstly, deselect the previous image 134 # Firstly, deselect the previous image
136 if self.curr_image_path: 135 userp, _ = self.model.get_selected_packages()
137 self.toggle_package(self.curr_image_path, model) 136 self.model.reset()
138 # Now select the new image and save its path in case we 137 # Now select the new image and save its path in case we
139 # change the image later 138 # change the image later
140 self.curr_image_path = path
141 self.toggle_package(path, model, image=True) 139 self.toggle_package(path, model, image=True)
140 if len(userp):
141 self.model.set_selected_packages(userp)
142 142
143 def reload_triggered_cb(self, handler, image, packages): 143 def reload_triggered_cb(self, handler, image, packages):
144 if image: 144 if image:
@@ -463,8 +463,8 @@ class MainWindow (gtk.Window):
463 return False 463 return False
464 464
465 def toggle_package(self, path, model, image=False): 465 def toggle_package(self, path, model, image=False):
466 # Warn user before removing packages
467 inc = model[path][self.model.COL_INC] 466 inc = model[path][self.model.COL_INC]
467 # Warn user before removing included packages
468 if inc: 468 if inc:
469 pn = model[path][self.model.COL_NAME] 469 pn = model[path][self.model.COL_NAME]
470 revdeps = self.model.find_reverse_depends(pn) 470 revdeps = self.model.find_reverse_depends(pn)