diff options
author | Shane Wang <shane.wang@intel.com> | 2012-04-09 22:13:36 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-04-11 00:04:44 +0100 |
commit | 8d353411c10a75de109eb5853fdc0b23bfca763a (patch) | |
tree | e114e3e5a15c91c81d8b07145f3ec5cf36432444 /bitbake/lib | |
parent | e2c1092905ceb0e7fc0a6141a9d3e36b89ec31f4 (diff) | |
download | poky-8d353411c10a75de109eb5853fdc0b23bfca763a.tar.gz |
Hob: clean up and unify the steps for new build to call initiate_new_build_async()
initiate_new_build() (changed the function name into initiate_new_build_async()
to indicate it is an async function) or the similar sub-functions are called at
different places.
This patch is unify to call initiate_new_build_async().
(Bitbake rev: ec42be626a5d6362a09f12f4f4025ad92d70c89b)
Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rwxr-xr-x | bitbake/lib/bb/ui/crumbs/builder.py | 19 | ||||
-rwxr-xr-x | bitbake/lib/bb/ui/crumbs/imagedetailspage.py | 2 |
2 files changed, 8 insertions, 13 deletions
diff --git a/bitbake/lib/bb/ui/crumbs/builder.py b/bitbake/lib/bb/ui/crumbs/builder.py index bc7e61094c..0f32d33b2e 100755 --- a/bitbake/lib/bb/ui/crumbs/builder.py +++ b/bitbake/lib/bb/ui/crumbs/builder.py | |||
@@ -297,11 +297,7 @@ class Builder(gtk.Window): | |||
297 | self.handler.connect("command-succeeded", self.handler_command_succeeded_cb) | 297 | self.handler.connect("command-succeeded", self.handler_command_succeeded_cb) |
298 | self.handler.connect("command-failed", self.handler_command_failed_cb) | 298 | self.handler.connect("command-failed", self.handler_command_failed_cb) |
299 | 299 | ||
300 | self.handler.init_cooker() | 300 | self.initiate_new_build_async() |
301 | self.handler.set_extra_inherit("image_types") | ||
302 | self.handler.parse_config() | ||
303 | |||
304 | self.switch_page(self.MACHINE_SELECTION) | ||
305 | 301 | ||
306 | def create_visual_elements(self): | 302 | def create_visual_elements(self): |
307 | self.set_title("Hob") | 303 | self.set_title("Hob") |
@@ -337,6 +333,12 @@ class Builder(gtk.Window): | |||
337 | self.show_all() | 333 | self.show_all() |
338 | self.nb.set_current_page(0) | 334 | self.nb.set_current_page(0) |
339 | 335 | ||
336 | def initiate_new_build_async(self): | ||
337 | self.switch_page(self.MACHINE_SELECTION) | ||
338 | self.handler.init_cooker() | ||
339 | self.handler.set_extra_inherit("image_types") | ||
340 | self.handler.parse_config() | ||
341 | |||
340 | def load_template(self, path): | 342 | def load_template(self, path): |
341 | self.template = TemplateMgr() | 343 | self.template = TemplateMgr() |
342 | self.template.load(path) | 344 | self.template.load(path) |
@@ -990,13 +992,6 @@ class Builder(gtk.Window): | |||
990 | def show_recipes(self): | 992 | def show_recipes(self): |
991 | self.switch_page(self.RECIPE_SELECTION) | 993 | self.switch_page(self.RECIPE_SELECTION) |
992 | 994 | ||
993 | def initiate_new_build(self): | ||
994 | self.handler.init_cooker() | ||
995 | self.handler.set_extra_inherit("image_types") | ||
996 | self.handler.parse_config() | ||
997 | self.image_configuration_page.switch_machine_combo() | ||
998 | self.switch_page(self.MACHINE_SELECTION) | ||
999 | |||
1000 | def show_configuration(self): | 995 | def show_configuration(self): |
1001 | self.switch_page(self.BASEIMG_SELECTED) | 996 | self.switch_page(self.BASEIMG_SELECTED) |
1002 | 997 | ||
diff --git a/bitbake/lib/bb/ui/crumbs/imagedetailspage.py b/bitbake/lib/bb/ui/crumbs/imagedetailspage.py index 277f9d4b4d..be112d43d7 100755 --- a/bitbake/lib/bb/ui/crumbs/imagedetailspage.py +++ b/bitbake/lib/bb/ui/crumbs/imagedetailspage.py | |||
@@ -380,7 +380,7 @@ class ImageDetailsPage (HobPage): | |||
380 | self.builder.runqemu_image(image_name) | 380 | self.builder.runqemu_image(image_name) |
381 | 381 | ||
382 | def build_new_button_clicked_cb(self, button): | 382 | def build_new_button_clicked_cb(self, button): |
383 | self.builder.initiate_new_build() | 383 | self.builder.initiate_new_build_async() |
384 | 384 | ||
385 | def edit_config_button_clicked_cb(self, button): | 385 | def edit_config_button_clicked_cb(self, button): |
386 | self.builder.show_configuration() | 386 | self.builder.show_configuration() |