Openembedded Bitbake Development
 help / color / mirror / Atom feed
From: Joshua Lock <josh@linux.intel.com>
To: bitbake-devel@lists.openembedded.org
Subject: Re: [PATCH 11/32] Hob: make the image configuration page not to flash the progress bar
Date: Wed, 29 Feb 2012 13:29:07 -0800	[thread overview]
Message-ID: <4F4E98A3.20501@linux.intel.com> (raw)
In-Reply-To: <01a2bab8db48a197f25682f9a5673a399e20be7d.1330523904.git.shane.wang@intel.com>

On 29/02/12 06:15, Shane Wang wrote:
> Sometimes the image configuration page flashes the progress bar, that is because we show_all() and then hide() the progress bar. For this case, the patch doesn't add the progress bar onto the gtable. Then, it will not be flashed any more.
>
> Signed-off-by: Shane Wang<shane.wang@intel.com>

I'm not a fan of show_all() but this looks fine:

Signed-off-by: Joshua Lock <josh@linux.intel.com>

> ---
>   bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py |   30 +++++++++----------
>   1 files changed, 14 insertions(+), 16 deletions(-)
>
> diff --git a/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py b/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
> index cd86606..db54d79 100644
> --- a/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
> +++ b/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py
> @@ -84,21 +84,20 @@ class ImageConfigurationPage (HobPage):
>           for child in children:
>               self.remove(child)
>
> -    def _pack_components(self):
> +    def _pack_components(self, pack_config_build_button = False):
>           self._remove_all_widget()
>           self.pack_start(self.config_top_button, expand=False, fill=False)
>           self.pack_start(self.group_align, expand=True, fill=True)
>
>           self.box_group_area.pack_start(self.gtable, expand=True, fill=True)
> -        self.box_group_area.pack_end(self.config_build_button, expand=False, fill=False)
> +        if pack_config_build_button == True:
> +            self.box_group_area.pack_end(self.config_build_button, expand=False, fill=False)
>
>       def show_machine(self):
> -        self._pack_components()
> -        self.set_config_machine_layout()
> -        self.show_all()
>           self.progress_bar.reset()
> -        self.progress_bar.hide()
> -        self.config_build_button.hide_all()
> +        self._pack_components(pack_config_build_button = False)
> +        self.set_config_machine_layout(show_progress_bar = False)
> +        self.show_all()
>
>       def update_progress_bar(self, title, fraction, status=True):
>           self.progress_bar.update(fraction)
> @@ -106,18 +105,16 @@ class ImageConfigurationPage (HobPage):
>           self.progress_bar.set_rcstyle(status)
>
>       def show_info_populating(self):
> -        self._pack_components()
> -        self.set_config_machine_layout()
> +        self._pack_components(pack_config_build_button = False)
> +        self.set_config_machine_layout(show_progress_bar = True)
>           self.show_all()
> -        self.config_build_button.hide_all()
>
>       def show_info_populated(self):
> -        self._pack_components()
> -        self.set_config_machine_layout()
> +        self.progress_bar.reset()
> +        self._pack_components(pack_config_build_button = True)
> +        self.set_config_machine_layout(show_progress_bar = False)
>           self.set_config_baseimg_layout()
>           self.show_all()
> -        self.progress_bar.reset()
> -        self.progress_bar.hide()
>
>       def create_config_machine(self):
>           self.machine_title = gtk.Label()
> @@ -154,13 +151,14 @@ class ImageConfigurationPage (HobPage):
>           self.progress_bar = HobProgressBar()
>           self.machine_separator = gtk.HSeparator()
>
> -    def set_config_machine_layout(self):
> +    def set_config_machine_layout(self, show_progress_bar = False):
>           self.gtable.attach(self.machine_title, 0, 40, 0, 4)
>           self.gtable.attach(self.machine_title_desc, 0, 40, 4, 6)
>           self.gtable.attach(self.machine_combo, 0, 12, 6, 9)
>           self.gtable.attach(self.layer_button, 12, 36, 6, 10)
>           self.gtable.attach(self.layer_info_icon, 36, 40, 6, 9)
> -        self.gtable.attach(self.progress_bar, 0, 40, 13, 17)
> +        if show_progress_bar == True:
> +            self.gtable.attach(self.progress_bar, 0, 40, 13, 17)
>           self.gtable.attach(self.machine_separator, 0, 40, 12, 13)
>
>       def create_config_baseimg(self):

-- 
Joshua Lock
         Yocto Project "Johannes factotum"
         Intel Open Source Technology Centre



  reply	other threads:[~2012-02-29 21:37 UTC|newest]

Thread overview: 81+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-29 14:11 [PATCH 00/32] Hob related fixes Shane Wang
2012-02-29 14:14 ` [PATCH 01/32] Hob: make HobViewTable more general in hob and make the image selection dialog and the image details page reuse it Shane Wang
2012-02-29 21:28   ` Joshua Lock
2012-03-02  7:19     ` Wang, Shane
2012-02-29 14:14 ` [PATCH 02/32] Hob: avoid the image selection dialog to walk through all directories and its sub-directories, when users click "My images" Shane Wang
2012-02-29 21:30   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 03/32] Hob: cleanup those class methods in HobWidget Shane Wang
2012-02-29 14:15 ` [PATCH 04/32] Hob: fixed the issue in the brought-in-by dialog Shane Wang
2012-02-29 21:28   ` Joshua Lock
2012-03-02  7:22     ` Wang, Shane
2012-03-02 18:02       ` Joshua Lock
2012-03-07 23:21         ` Wang, Shane
2012-03-07 23:56           ` Joshua Lock
2012-02-29 14:15 ` [PATCH 05/32] Hob: include hddimg and iso into image types Shane Wang
2012-02-29 21:27   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 06/32] Hob: implement a self-defined notebook visual component for Hob Shane Wang
2012-02-29 21:27   ` Joshua Lock
2012-03-02  7:06     ` Wang, Shane
2012-03-02 18:06       ` Joshua Lock
2012-02-29 14:15 ` [PATCH 07/32] Hob: use HobNotebook to enable a notebook in build details page Shane Wang
2012-02-29 21:32   ` Joshua Lock
2012-03-02 13:34     ` Wang, Shane
2012-02-29 14:15 ` [PATCH 08/32] Hob: image configuration page doesn't need dialogs any more Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 09/32] Hob: fix a bug in builder.configuration.curr_mach Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 10/32] Hob: add ignore_all_errors to avoid showing error dialog multiple times Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-03-02  7:31     ` Wang, Shane
2012-02-29 14:15 ` [PATCH 11/32] Hob: make the image configuration page not to flash the progress bar Shane Wang
2012-02-29 21:29   ` Joshua Lock [this message]
2012-02-29 14:15 ` [PATCH 12/32] Hob: enable indicators on the "Included" tab in the recipe selection page and the package selection page Shane Wang
2012-02-29 14:15 ` [PATCH 13/32] crumbs: Factor common dialogue configuration out Shane Wang
2012-02-29 14:15 ` [PATCH 14/32] crumbs/builder: use the name Hob consistently Shane Wang
2012-02-29 14:15 ` [PATCH 15/32] crumbs: move towards more standard dialogue spacing Shane Wang
2012-02-29 14:15 ` [PATCH 16/32] crumbs: fix button order in several dialogues Shane Wang
2012-02-29 14:15 ` [PATCH 17/32] hig: try to avoid setting explicit dialogue sizes Shane Wang
2012-02-29 14:15 ` [PATCH 18/32] crumbs/hig: tweak UI and layout of LayerSelectionDialog Shane Wang
2012-02-29 14:15 ` [PATCH 19/32] Hob(crumbs/builder.py): remove the code commented out in the builder.py Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 20/32] command.py: remove the resolve parameter in generateTargetsTree Shane Wang
2012-02-29 21:28   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 21/32] cooker.py: Fix a bug due to variable name Shane Wang
2012-02-29 21:28   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 22/32] cooker: fix calculating of depends and rdepends Shane Wang
2012-02-29 21:28   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 23/32] Hob(crumbs/hoblistmodel.py): Fix recipe's populate() function Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 24/32] Hob(crumbs/hoblistmodel.py): Add mapping for rprovides and pkg Shane Wang
2012-02-29 21:30   ` Joshua Lock
2012-03-01  4:20     ` Xu, Dongxiao
2012-03-02 13:31     ` Wang, Shane
2012-02-29 14:15 ` [PATCH 25/32] Hob: Add an extra 50M space if zypper is selected Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-03-01  4:19     ` Xu, Dongxiao
2012-03-01 19:22       ` Joshua Lock
2012-02-29 14:15 ` [PATCH 26/32] Hob: fix a bug that the image size is shown incorrectly in the image details page Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 27/32] Hob: add "OK" button to "BinbDialog" Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-03-01  4:20     ` Xu, Dongxiao
2012-03-02 13:29     ` Wang, Shane
2012-02-29 14:15 ` [PATCH 28/32] Hob: allow users to setup the proxy Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-03-02 13:29     ` Wang, Shane
2012-03-02 18:14       ` Joshua Lock
2012-02-29 14:15 ` [PATCH 29/32] Hob(crumbs/builder.py): adjust the main window's position and ignore the case lower than 1024x768 Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 30/32] Hob: Fix pressing "stop" build Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 31/32] runqueue.py: initialize rqexe at RunQueue's init function Shane Wang
2012-02-29 21:29   ` Joshua Lock
2012-02-29 14:15 ` [PATCH 32/32] Hob: Disable the handling of "NoProvider" event Shane Wang
2012-03-01 15:23   ` Richard Purdie
2012-03-02  1:24     ` Xu, Dongxiao
2012-02-29 21:27 ` [PATCH 00/32] Hob related fixes Joshua Lock
2012-03-02  6:48   ` Wang, Shane
2012-03-03  3:50     ` Oren Leaffer
2012-03-01 15:32 ` Richard Purdie
2012-03-01 15:35 ` Richard Purdie
2012-03-02  1:23   ` Wang, Shane

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F4E98A3.20501@linux.intel.com \
    --to=josh@linux.intel.com \
    --cc=bitbake-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox