Only try to pop down the submenus if we still have a _Menu #1338
This commit is contained in:
parent
0159bc7b52
commit
850a78c59a
@ -943,8 +943,6 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):
|
||||
|
||||
self.set_palette(Palette(text))
|
||||
|
||||
palette = property(get_palette, set_palette)
|
||||
|
||||
|
||||
class CellRendererIcon(gtk.GenericCellRenderer):
|
||||
|
||||
|
@ -209,6 +209,7 @@ class Palette(PaletteWindow):
|
||||
def _popdown_submenus(self):
|
||||
# TODO explicit hiding of subitems
|
||||
# should be removed after fixing #1301
|
||||
if self.menu is not None:
|
||||
for menu_item in self.menu.get_children():
|
||||
if menu_item.props.submenu is not None:
|
||||
menu_item.props.submenu.popdown()
|
||||
|
Loading…
Reference in New Issue
Block a user