From patchwork Tue Mar 27 18:25:48 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [bitbake-devel, 4/6] Hob: use hob icon checker to check the gtk icon for make the icon constaintly Date: Tue, 27 Mar 2012 18:25:48 -0000 From: An, LimingX L X-Patchwork-Id: 24669 Message-Id: <0f8af992885f0ab228e6aa9c70f9b0b489d05c8f.1332871932.git.limingx.l.an@intel.com> To: bitbake-devel@lists.openembedded.org Because we have hob icon, so need to make some gtk icon to transfer to hob icon. so use hob icon checker to fixed the gtk icon [YOCTO #2108] Signed-off-by: Liming An --- bitbake/lib/bb/ui/crumbs/hig.py | 8 +++----- 1 files changed, 3 insertions(+), 5 deletions(-) diff --git a/bitbake/lib/bb/ui/crumbs/hig.py b/bitbake/lib/bb/ui/crumbs/hig.py index 6ae682b..d151fc4 100644 --- a/bitbake/lib/bb/ui/crumbs/hig.py +++ b/bitbake/lib/bb/ui/crumbs/hig.py @@ -28,7 +28,7 @@ import re import subprocess import shlex from bb.ui.crumbs.hobcolor import HobColors -from bb.ui.crumbs.hobwidget import hcc, hic, HobViewTable, HobInfoButton +from bb.ui.crumbs.hobwidget import hcc, hic, HobViewTable, HobInfoButton, HobAltButton, HobIconChecker from bb.ui.crumbs.progressbar import HobProgressBar """ @@ -75,10 +75,8 @@ class CrumbsMessageDialog(CrumbsDialog): self.icon = gtk.Image() # We have our own Info icon which should be used in preference of the stock icon - if icon == gtk.STOCK_INFO or icon == "gtk-dialog-info": - self.icon.set_from_file(hic.ICON_INFO_DISPLAY_FILE) - else: - self.icon.set_from_stock(icon, gtk.ICON_SIZE_DIALOG) + self.icon_chk = HobIconChecker() + self.icon.set_from_stock(self.icon_chk.check_stock_icon(icon), gtk.ICON_SIZE_DIALOG) self.icon.set_property("yalign", 0.00) self.icon.show() first_row.add(self.icon)