lib/bb/ui/crumbs: use a PersistentTooltip for the Brought in by information
(Bitbake rev: c57a45c64a17f1b9dd89743692c3da130ffd38f4) Signed-off-by: Joshua Lock <josh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
2206679669
commit
fb7eb75f33
|
@ -33,9 +33,10 @@ from bb.ui.crumbs.packageselectionpage import PackageSelectionPage
|
|||
from bb.ui.crumbs.builddetailspage import BuildDetailsPage
|
||||
from bb.ui.crumbs.imagedetailspage import ImageDetailsPage
|
||||
from bb.ui.crumbs.hobwidget import hwc
|
||||
from bb.ui.crumbs.hig import CrumbsMessageDialog, BinbDialog, \
|
||||
from bb.ui.crumbs.hig import CrumbsMessageDialog, ImageSelectionDialog, \
|
||||
AdvancedSettingDialog, LayerSelectionDialog, \
|
||||
DeployImageDialog, ImageSelectionDialog
|
||||
DeployImageDialog
|
||||
from bb.ui.crumbs.persistenttooltip import PersistentTooltip
|
||||
|
||||
class Configuration:
|
||||
'''Represents the data structure of configuration.'''
|
||||
|
@ -668,9 +669,10 @@ class Builder(gtk.Window):
|
|||
self.switch_page(self.FAST_IMAGE_GENERATING)
|
||||
|
||||
def show_binb_dialog(self, binb):
|
||||
binb_dialog = BinbDialog("Brought in by:", binb, self)
|
||||
binb_dialog.run()
|
||||
binb_dialog.destroy()
|
||||
markup = "<b>Brought in by:</b>\n%s" % binb
|
||||
ptip = PersistentTooltip(markup)
|
||||
|
||||
ptip.show()
|
||||
|
||||
def show_layer_selection_dialog(self):
|
||||
dialog = LayerSelectionDialog(title = "Layers",
|
||||
|
|
|
@ -91,29 +91,6 @@ class CrumbsMessageDialog(CrumbsDialog):
|
|||
self.label.show()
|
||||
first_row.add(self.label)
|
||||
|
||||
#
|
||||
# Brought-in-by Dialog
|
||||
#
|
||||
class BinbDialog(CrumbsDialog):
|
||||
"""
|
||||
A dialog widget to show "brought in by" info when a recipe/package is clicked.
|
||||
"""
|
||||
|
||||
def __init__(self, title, content, parent=None):
|
||||
super(BinbDialog, self).__init__(title, parent, gtk.DIALOG_MODAL | gtk.DIALOG_DESTROY_WITH_PARENT, ("Close", gtk.RESPONSE_CLOSE))
|
||||
|
||||
self.set_position(gtk.WIN_POS_MOUSE)
|
||||
self.set_resizable(False)
|
||||
self.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.DARK))
|
||||
|
||||
label = gtk.Label(content)
|
||||
label.set_alignment(0, 0)
|
||||
label.set_line_wrap(True)
|
||||
label.modify_fg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.WHITE))
|
||||
|
||||
self.vbox.pack_start(label, expand=True, fill=True, padding=10)
|
||||
self.vbox.show_all()
|
||||
|
||||
#
|
||||
# AdvancedSettings Dialog
|
||||
#
|
||||
|
|
Loading…
Reference in New Issue