fix avatar save popup menu
This commit is contained in:
parent
9cd0ca803b
commit
4460d51d79
|
@ -183,7 +183,7 @@ class VcardWindow:
|
|||
"""
|
||||
if event.button == 3: # right click
|
||||
menu = Gtk.Menu()
|
||||
menuitem = Gtk.ImageMenuItem(Gtk.STOCK_SAVE_AS)
|
||||
menuitem = Gtk.ImageMenuItem.new_from_stock(Gtk.STOCK_SAVE_AS, None)
|
||||
menuitem.connect('activate',
|
||||
gtkgui_helpers.on_avatar_save_as_menuitem_activate,
|
||||
self.contact.jid, self.contact.get_shown_name())
|
||||
|
@ -191,6 +191,7 @@ class VcardWindow:
|
|||
menu.connect('selection-done', lambda w:w.destroy())
|
||||
# show the menu
|
||||
menu.show_all()
|
||||
menu.attach_to_widget(widget, None)
|
||||
menu.popup(None, None, None, None, event.button, event.time)
|
||||
|
||||
def set_value(self, entry_name, value):
|
||||
|
@ -525,7 +526,7 @@ class ZeroconfVcardWindow:
|
|||
"""
|
||||
if event.button == 3: # right click
|
||||
menu = Gtk.Menu()
|
||||
menuitem = Gtk.ImageMenuItem(Gtk.STOCK_SAVE_AS)
|
||||
menuitem = Gtk.ImageMenuItem.new_from_stock(Gtk.STOCK_SAVE_AS, None)
|
||||
menuitem.connect('activate',
|
||||
gtkgui_helpers.on_avatar_save_as_menuitem_activate,
|
||||
self.contact.jid, self.contact.get_shown_name())
|
||||
|
@ -533,6 +534,7 @@ class ZeroconfVcardWindow:
|
|||
menu.connect('selection-done', lambda w:w.destroy())
|
||||
# show the menu
|
||||
menu.show_all()
|
||||
menu.attach_to_widget(widget, None)
|
||||
menu.popup(None, None, None, None, event.button, event.time)
|
||||
|
||||
def set_value(self, entry_name, value):
|
||||
|
|
Loading…
Reference in New Issue