* [PATCH 0/1] ui/depexp.py: use the new progressbar in Hob
@ 2012-06-19 9:39 Kang Kai
2012-06-19 9:39 ` [PATCH 1/1] " Kang Kai
0 siblings, 1 reply; 3+ messages in thread
From: Kang Kai @ 2012-06-19 9:39 UTC (permalink / raw)
To: bitbake-devel; +Cc: Zhenfeng.Zhao
Hi,
This patch is about Yocto 2149, use the new progressbar in Hob to reduce the maintenance burden of the multiple GUIs.
Regards,
Kai
The following changes since commit e0a70547069fe7e8a2d6bdaffc985fb172d46c31:
perl: Allow perl to cross build and native build in a directory named "t" (2012-06-18 17:33:04 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib kangkai/distro
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kangkai/distro
Kang Kai (1):
ui/depexp.py: use the new progressbar in Hob
bitbake/lib/bb/ui/depexp.py | 29 ++++++++++++++++++-----------
1 files changed, 18 insertions(+), 11 deletions(-)
--
1.7.5.4
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 1/1] ui/depexp.py: use the new progressbar in Hob
2012-06-19 9:39 [PATCH 0/1] ui/depexp.py: use the new progressbar in Hob Kang Kai
@ 2012-06-19 9:39 ` Kang Kai
2012-06-21 12:17 ` Richard Purdie
0 siblings, 1 reply; 3+ messages in thread
From: Kang Kai @ 2012-06-19 9:39 UTC (permalink / raw)
To: bitbake-devel; +Cc: Zhenfeng.Zhao
[Yocto 2149]
Use the new progressbar in Hob, so that we can reduce the maintenance
burden of the multiple GUIs.
Signed-off-by: Kang Kai <kai.kang@windriver.com>
---
bitbake/lib/bb/ui/depexp.py | 29 ++++++++++++++++++-----------
1 files changed, 18 insertions(+), 11 deletions(-)
diff --git a/bitbake/lib/bb/ui/depexp.py b/bitbake/lib/bb/ui/depexp.py
index b62adbf..425302e 100644
--- a/bitbake/lib/bb/ui/depexp.py
+++ b/bitbake/lib/bb/ui/depexp.py
@@ -24,7 +24,7 @@ import threading
import xmlrpclib
import bb
import bb.event
-from bb.ui.crumbs.progress import ProgressBar
+from bb.ui.crumbs.progressbar import HobProgressBar
# Package Model
(COL_PKG_NAME) = (0)
@@ -220,8 +220,12 @@ def main(server, eventHandler):
gtk.gdk.threads_enter()
dep = DepExplorer()
- pbar = ProgressBar(dep)
- pbar.connect("delete-event", gtk.main_quit)
+ bardialog = gtk.Dialog(parent=dep)
+ bardialog.set_default_size(400, 50)
+ pbar = HobProgressBar()
+ bardialog.vbox.pack_start(pbar)
+ bardialog.show_all()
+ bardialog.connect("delete-event", gtk.main_quit)
gtk.gdk.threads_leave()
progress_total = 0
@@ -238,19 +242,20 @@ def main(server, eventHandler):
if isinstance(event, bb.event.CacheLoadStarted):
progress_total = event.total
gtk.gdk.threads_enter()
- pbar.set_title("Loading Cache")
- pbar.update(0, progress_total)
+ bardialog.set_title("Loading Cache")
+ pbar.update(0)
gtk.gdk.threads_leave()
if isinstance(event, bb.event.CacheLoadProgress):
x = event.current
gtk.gdk.threads_enter()
- pbar.update(x, progress_total)
+ pbar.update(x * 1.0 / progress_total)
+ pbar.set_title('')
gtk.gdk.threads_leave()
continue
if isinstance(event, bb.event.CacheLoadCompleted):
- pbar.hide()
+ bardialog.hide()
continue
if isinstance(event, bb.event.ParseStarted):
@@ -258,19 +263,21 @@ def main(server, eventHandler):
if progress_total == 0:
continue
gtk.gdk.threads_enter()
- pbar.set_title("Processing recipes")
- pbar.update(0, progress_total)
+ pbar.update(0)
+ bardialog.set_title("Processing recipes")
+
gtk.gdk.threads_leave()
if isinstance(event, bb.event.ParseProgress):
x = event.current
gtk.gdk.threads_enter()
- pbar.update(x, progress_total)
+ pbar.update(x * 1.0 / progress_total)
+ pbar.set_title('')
gtk.gdk.threads_leave()
continue
if isinstance(event, bb.event.ParseCompleted):
- pbar.hide()
+ bardialog.hide()
continue
if isinstance(event, bb.event.DepTreeGenerated):
--
1.7.5.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] ui/depexp.py: use the new progressbar in Hob
2012-06-19 9:39 ` [PATCH 1/1] " Kang Kai
@ 2012-06-21 12:17 ` Richard Purdie
0 siblings, 0 replies; 3+ messages in thread
From: Richard Purdie @ 2012-06-21 12:17 UTC (permalink / raw)
To: Kang Kai; +Cc: bitbake-devel, Zhenfeng.Zhao
On Tue, 2012-06-19 at 17:39 +0800, Kang Kai wrote:
> [Yocto 2149]
>
> Use the new progressbar in Hob, so that we can reduce the maintenance
> burden of the multiple GUIs.
>
> Signed-off-by: Kang Kai <kai.kang@windriver.com>
> ---
> bitbake/lib/bb/ui/depexp.py | 29 ++++++++++++++++++-----------
> 1 files changed, 18 insertions(+), 11 deletions(-)
Merged to master, thanks.
Richard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-06-21 12:28 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-19 9:39 [PATCH 0/1] ui/depexp.py: use the new progressbar in Hob Kang Kai
2012-06-19 9:39 ` [PATCH 1/1] " Kang Kai
2012-06-21 12:17 ` Richard Purdie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox