show better icon for send file menuitems / buttons. Fixes #4282

This commit is contained in:
Yann Leboulanger 2008-09-08 11:27:37 +00:00
parent f260d83c80
commit 9a8dd5db02
5 changed files with 30 additions and 1 deletions

View File

@ -276,7 +276,6 @@
<widget class="GtkImage" id="image3">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<property name="stock">gtk-save</property>
<property name="icon_size">1</property>
</widget>
</child>

BIN
data/pixmaps/upload.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 780 B

View File

@ -1025,6 +1025,11 @@ class ChatControl(ChatControlBase):
self.handlers[id] = self._add_to_roster_button
self._send_file_button = self.xml.get_widget('send_file_button')
# add a special img for send file button
path_to_upload_img = os.path.join(gajim.DATA_DIR, 'pixmaps', 'upload.png')
img = gtk.Image()
img.set_from_file(path_to_upload_img)
self._send_file_button.set_image(img)
id = self._send_file_button.connect('clicked',
self._on_send_file_menuitem_activate)
self.handlers[id] = self._send_file_button
@ -1970,6 +1975,12 @@ class ChatControl(ChatControlBase):
separatormenuitem1 = xml.get_widget('separatormenuitem1')
separatormenuitem2 = xml.get_widget('separatormenuitem2')
# add a special img for send file menuitem
path_to_upload_img = os.path.join(gajim.DATA_DIR, 'pixmaps', 'upload.png')
img = gtk.Image()
img.set_from_file(path_to_upload_img)
send_file_menuitem.set_image(img)
muc_icon = gtkgui_helpers.load_icon('muc_active')
if muc_icon:
convert_to_gc_menuitem.set_image(muc_icon)

View File

@ -2109,6 +2109,12 @@ class GroupchatControl(ChatControlBase):
self.handlers[id] = item
item = xml.get_widget('send_file_menuitem')
# add a special img for send file menuitem
path_to_upload_img = os.path.join(gajim.DATA_DIR, 'pixmaps', 'upload.png')
img = gtk.Image()
img.set_from_file(path_to_upload_img)
item.set_image(img)
if not c.resource:
item.set_sensitive(False)
else:

View File

@ -5163,6 +5163,13 @@ class RosterWindow:
add_special_notification_menuitem = xml.get_widget(
'add_special_notification_menuitem')
# add a special img for send file menuitem
path_to_upload_img = os.path.join(gajim.DATA_DIR, 'pixmaps',
'upload.png')
img = gtk.Image()
img.set_from_file(path_to_upload_img)
send_file_menuitem.set_image(img)
if not our_jid:
# add a special img for rename menuitem
path_to_kbd_input_img = os.path.join(gajim.DATA_DIR, 'pixmaps',
@ -5285,6 +5292,12 @@ class RosterWindow:
execute_command_menuitem = xml.get_widget(
'execute_command_menuitem')
# add a special img for send file menuitem
path_to_upload_img = os.path.join(gajim.DATA_DIR, 'pixmaps', 'upload.png')
img = gtk.Image()
img.set_from_file(path_to_upload_img)
send_file_menuitem.set_image(img)
# send custom status icon
blocked = False
if jid in gajim.connections[account].blocked_contacts: