Hob: fixed the index issue when set actived item for base image combo
authorLiming An <limingx.l.an@intel.com>
Mon, 4 Jun 2012 10:52:14 +0000 (18:52 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 8 Jun 2012 11:13:16 +0000 (12:13 +0100)
The combo item index dosn't be increased as the insert a dummy item, when
execute the upadate base image combo operation.

[YOCTO #2500]

(Bitbake rev: 59e19634a84fcb4c34b92cdcf7a9ea807c9abb63)

Signed-off-by: Liming An <limingx.l.an@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py

index b5f0a5a..80332fe 100644 (file)
@@ -364,7 +364,7 @@ class ImageConfigurationPage (HobPage):
         filter = {RecipeListModel.COL_TYPE : ['image']}
         image_model = recipe_model.tree_model(filter)
         active = 0
-        cnt = 0
+        cnt = 1
 
         white_pattern = []
         if self.builder.parameters.image_white_pattern:
@@ -415,7 +415,6 @@ class ImageConfigurationPage (HobPage):
         if selected_image == self.builder.recipe_model.__custom_image__:
             active = cnt
 
-        self.image_combo.set_active(0)
         self.image_combo.set_active(active)
 
         if active != 0: