ability to see pep nodes and their access model. TODO: ability to change it
This commit is contained in:
parent
e3ef0821b3
commit
07b324ced4
|
@ -1,141 +1,94 @@
|
||||||
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
<!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd">
|
||||||
|
<!--*- mode: xml -*-->
|
||||||
<glade-interface>
|
<glade-interface>
|
||||||
|
<widget class="GtkWindow" id="roster_window">
|
||||||
<widget class="GtkWindow" id="roster_window">
|
|
||||||
<property name="width_request">85</property>
|
<property name="width_request">85</property>
|
||||||
<property name="height_request">200</property>
|
<property name="height_request">200</property>
|
||||||
<property name="title" translatable="yes">Gajim</property>
|
<property name="title" translatable="yes">Gajim</property>
|
||||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
<property name="role">roster</property>
|
||||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
|
||||||
<property name="modal">False</property>
|
|
||||||
<property name="default_width">200</property>
|
<property name="default_width">200</property>
|
||||||
<property name="default_height">400</property>
|
<property name="default_height">400</property>
|
||||||
<property name="resizable">True</property>
|
<signal name="popup_menu" handler="on_roster_window_popup_menu"/>
|
||||||
<property name="destroy_with_parent">False</property>
|
<signal name="focus_out_event" handler="on_roster_window_focus_out_event"/>
|
||||||
<property name="role">roster</property>
|
<signal name="focus_in_event" handler="on_roster_window_focus_in_event"/>
|
||||||
<property name="decorated">True</property>
|
<signal name="key_press_event" handler="on_roster_window_key_press_event"/>
|
||||||
<property name="skip_taskbar_hint">False</property>
|
<signal name="delete_event" handler="on_roster_window_delete_event"/>
|
||||||
<property name="skip_pager_hint">False</property>
|
|
||||||
<property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
|
|
||||||
<property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
|
|
||||||
<property name="focus_on_map">True</property>
|
|
||||||
<property name="urgency_hint">False</property>
|
|
||||||
<signal name="delete_event" handler="on_roster_window_delete_event" last_modification_time="Mon, 21 Mar 2005 12:34:59 GMT"/>
|
|
||||||
<signal name="focus_in_event" handler="on_roster_window_focus_in_event" last_modification_time="Sun, 04 Sep 2005 16:33:35 GMT"/>
|
|
||||||
<signal name="key_press_event" handler="on_roster_window_key_press_event" last_modification_time="Tue, 20 Sep 2005 19:26:27 GMT"/>
|
|
||||||
<signal name="focus_out_event" handler="on_roster_window_focus_out_event" last_modification_time="Tue, 08 Nov 2005 14:01:01 GMT"/>
|
|
||||||
<signal name="popup_menu" handler="on_roster_window_popup_menu" last_modification_time="Sat, 18 Nov 2006 21:12:06 GMT"/>
|
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkVBox" id="roster_vbox">
|
<widget class="GtkVBox" id="roster_vbox">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
<property name="spacing">0</property>
|
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuBar" id="menubar">
|
<widget class="GtkMenuBar" id="menubar">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="pack_direction">GTK_PACK_DIRECTION_LTR</property>
|
|
||||||
<property name="child_pack_direction">GTK_PACK_DIRECTION_LTR</property>
|
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="actions_menu">
|
<widget class="GtkMenuItem" id="actions_menu">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Actions</property>
|
<property name="label" translatable="yes">_Actions</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_actions_menuitem_activate" last_modification_time="Sun, 19 Feb 2006 17:10:56 GMT"/>
|
<signal name="activate" handler="on_actions_menuitem_activate"/>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenu" id="actions_menu_menu">
|
<widget class="GtkMenu" id="actions_menu_menu">
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="new_chat_menuitem">
|
<widget class="GtkImageMenuItem" id="new_chat_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Start Chat</property>
|
<property name="label" translatable="yes">_Start Chat</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1605">
|
<widget class="GtkImage" id="image1605">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-jump-to</property>
|
<property name="stock">gtk-jump-to</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="join_gc_menuitem">
|
<widget class="GtkImageMenuItem" id="join_gc_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Group Chat</property>
|
<property name="label" translatable="yes">_Group Chat</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1606">
|
<widget class="GtkImage" id="image1606">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-connect</property>
|
<property name="stock">gtk-connect</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkSeparatorMenuItem" id="separatormenuitem1">
|
<widget class="GtkSeparatorMenuItem" id="separatormenuitem1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="add_new_contact_menuitem">
|
<widget class="GtkImageMenuItem" id="add_new_contact_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">Add _Contact</property>
|
<property name="label" translatable="yes">Add _Contact</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1607">
|
<widget class="GtkImage" id="image1607">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-add</property>
|
<property name="stock">gtk-add</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="service_disco_menuitem">
|
<widget class="GtkImageMenuItem" id="service_disco_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Discover Services</property>
|
<property name="label" translatable="yes">_Discover Services</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1608">
|
<widget class="GtkImage" id="image1608">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-find</property>
|
<property name="stock">gtk-find</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="advanced_menuitem">
|
<widget class="GtkMenuItem" id="advanced_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
|
@ -143,30 +96,23 @@
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkSeparatorMenuItem" id="separator1">
|
<widget class="GtkSeparatorMenuItem" id="separator1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="quit_menuitem">
|
<widget class="GtkImageMenuItem" id="quit_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Quit</property>
|
<property name="label" translatable="yes">_Quit</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_quit_menuitem_activate" last_modification_time="Tue, 01 Mar 2005 23:37:49 GMT"/>
|
<signal name="activate" handler="on_quit_menuitem_activate"/>
|
||||||
<accelerator key="Q" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
<accelerator key="Q" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1609">
|
<widget class="GtkImage" id="image1609">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-quit</property>
|
<property name="stock">gtk-quit</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
@ -175,145 +121,119 @@
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="edit_menu">
|
<widget class="GtkMenuItem" id="edit_menu">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Edit</property>
|
<property name="label" translatable="yes">_Edit</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_edit_menuitem_activate" last_modification_time="Fri, 07 Apr 2006 22:46:56 GMT"/>
|
<signal name="activate" handler="on_edit_menuitem_activate"/>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenu" id="edit_menu_menu">
|
<widget class="GtkMenu" id="edit_menu_menu">
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="accounts_menuitem">
|
<widget class="GtkImageMenuItem" id="accounts_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">A_ccounts</property>
|
<property name="label" translatable="yes">A_ccounts</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_accounts_menuitem_activate" last_modification_time="Tue, 01 Mar 2005 23:23:19 GMT"/>
|
<signal name="activate" handler="on_accounts_menuitem_activate"/>
|
||||||
<accelerator key="A" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
<accelerator key="A" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1610">
|
<widget class="GtkImage" id="image1610">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-network</property>
|
<property name="stock">gtk-network</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="profile_avatar_menuitem">
|
<widget class="GtkImageMenuItem" id="profile_avatar_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">Profile, A_vatar</property>
|
<property name="label" translatable="yes">Profile, A_vatar</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1611">
|
<widget class="GtkImage" id="image1611">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-properties</property>
|
<property name="stock">gtk-properties</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkSeparatorMenuItem" id="separator2">
|
<widget class="GtkSeparatorMenuItem" id="separator2">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="preferences_menuitem">
|
<widget class="GtkImageMenuItem" id="preferences_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Preferences</property>
|
<property name="label" translatable="yes">_Preferences</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_preferences_menuitem_activate" last_modification_time="Tue, 01 Mar 2005 22:58:18 GMT"/>
|
<signal name="activate" handler="on_preferences_menuitem_activate"/>
|
||||||
<accelerator key="P" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
<accelerator key="P" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1612">
|
<widget class="GtkImage" id="image1612">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-preferences</property>
|
<property name="stock">gtk-preferences</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
</widget>
|
||||||
<property name="yalign">0.5</property>
|
</child>
|
||||||
<property name="xpad">0</property>
|
</widget>
|
||||||
<property name="ypad">0</property>
|
</child>
|
||||||
|
<child>
|
||||||
|
<widget class="GtkMenuItem" id="pep_services_menuitem">
|
||||||
|
<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="label" translatable="yes">_Services</property>
|
||||||
|
<property name="use_underline">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
|
||||||
</child>
|
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="view_menu">
|
<widget class="GtkMenuItem" id="view_menu">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_View</property>
|
<property name="label" translatable="yes">_View</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_view_menu_activate" last_modification_time="Fri, 29 Sep 2006 14:56:42 GMT"/>
|
<signal name="activate" handler="on_view_menu_activate"/>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenu" id="view_menu_menu">
|
<widget class="GtkMenu" id="view_menu_menu">
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkCheckMenuItem" id="show_offline_contacts_menuitem">
|
<widget class="GtkCheckMenuItem" id="show_offline_contacts_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">Show _Offline Contacts</property>
|
<property name="label" translatable="yes">Show _Offline Contacts</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<property name="active">False</property>
|
<signal name="activate" handler="on_show_offline_contacts_menuitem_activate"/>
|
||||||
<signal name="activate" handler="on_show_offline_contacts_menuitem_activate" last_modification_time="Tue, 01 Mar 2005 23:29:52 GMT"/>
|
|
||||||
<accelerator key="O" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
<accelerator key="O" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkCheckMenuItem" id="show_transports_menuitem">
|
<widget class="GtkCheckMenuItem" id="show_transports_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">Show Trans_ports</property>
|
<property name="label" translatable="yes">Show Trans_ports</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<property name="active">False</property>
|
<signal name="activate" handler="on_show_transports_menuitem_activate"/>
|
||||||
<signal name="activate" handler="on_show_transports_menuitem_activate" last_modification_time="Fri, 29 Sep 2006 15:35:28 GMT"/>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkSeparatorMenuItem" id="separator3">
|
<widget class="GtkSeparatorMenuItem" id="separator3">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="file_transfers_menuitem">
|
<widget class="GtkImageMenuItem" id="file_transfers_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">File _Transfers</property>
|
<property name="label" translatable="yes">File _Transfers</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_file_transfers_menuitem_activate" last_modification_time="Wed, 03 Aug 2005 15:44:28 GMT"/>
|
<signal name="activate" handler="on_file_transfers_menuitem_activate"/>
|
||||||
<accelerator key="T" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
<accelerator key="T" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1613">
|
<widget class="GtkImage" id="image1613">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-file</property>
|
<property name="stock">gtk-missing-image</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
@ -322,54 +242,45 @@
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="help_menu">
|
<widget class="GtkMenuItem" id="help_menu">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label" translatable="yes">_Help</property>
|
<property name="label" translatable="yes">_Help</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenu" id="help_menu_menu">
|
<widget class="GtkMenu" id="help_menu_menu">
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="contents_menuitem">
|
<widget class="GtkImageMenuItem" id="contents_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip" translatable="yes">Help online</property>
|
<property name="tooltip" translatable="yes">Help online</property>
|
||||||
<property name="label" translatable="yes">_Contents</property>
|
<property name="label" translatable="yes">_Contents</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_contents_menuitem_activate" last_modification_time="Thu, 06 Oct 2005 23:29:10 GMT"/>
|
<signal name="activate" handler="on_contents_menuitem_activate"/>
|
||||||
|
|
||||||
<child internal-child="image">
|
<child internal-child="image">
|
||||||
<widget class="GtkImage" id="image1614">
|
<widget class="GtkImage" id="image1614">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-help</property>
|
<property name="stock">gtk-help</property>
|
||||||
<property name="icon_size">1</property>
|
<property name="icon_size">1</property>
|
||||||
<property name="xalign">0.5</property>
|
|
||||||
<property name="yalign">0.5</property>
|
|
||||||
<property name="xpad">0</property>
|
|
||||||
<property name="ypad">0</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkMenuItem" id="faq_menuitem">
|
<widget class="GtkMenuItem" id="faq_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip" translatable="yes">Frequently Asked Questions (online)</property>
|
<property name="tooltip" translatable="yes">Frequently Asked Questions (online)</property>
|
||||||
<property name="label" translatable="yes">_FAQ</property>
|
<property name="label" translatable="yes">_FAQ</property>
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<signal name="activate" handler="on_faq_menuitem_activate" last_modification_time="Thu, 06 Oct 2005 23:29:10 GMT"/>
|
<signal name="activate" handler="on_faq_menuitem_activate"/>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkImageMenuItem" id="about_menuitem">
|
<widget class="GtkImageMenuItem" id="about_menuitem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label">gtk-about</property>
|
<property name="label">gtk-about</property>
|
||||||
|
<property name="use_underline">True</property>
|
||||||
<property name="use_stock">True</property>
|
<property name="use_stock">True</property>
|
||||||
<signal name="activate" handler="on_about_menuitem_activate" last_modification_time="Tue, 01 Mar 2005 22:56:45 GMT"/>
|
<signal name="activate" handler="on_about_menuitem_activate"/>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
@ -378,67 +289,50 @@
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="fill">False</property>
|
<property name="fill">False</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkScrolledWindow" id="scrolledwindow">
|
<widget class="GtkScrolledWindow" id="scrolledwindow">
|
||||||
<property name="border_width">2</property>
|
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can_focus">True</property>
|
<property name="can_focus">True</property>
|
||||||
|
<property name="border_width">2</property>
|
||||||
<property name="hscrollbar_policy">GTK_POLICY_NEVER</property>
|
<property name="hscrollbar_policy">GTK_POLICY_NEVER</property>
|
||||||
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
||||||
<property name="shadow_type">GTK_SHADOW_NONE</property>
|
|
||||||
<property name="window_placement">GTK_CORNER_TOP_LEFT</property>
|
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkTreeView" id="roster_treeview">
|
<widget class="GtkTreeView" id="roster_treeview">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can_focus">True</property>
|
<property name="can_focus">True</property>
|
||||||
<property name="headers_visible">False</property>
|
<property name="headers_visible">False</property>
|
||||||
<property name="rules_hint">False</property>
|
|
||||||
<property name="reorderable">True</property>
|
<property name="reorderable">True</property>
|
||||||
<property name="enable_search">True</property>
|
<signal name="leave_notify_event" handler="on_roster_treeview_leave_notify_event"/>
|
||||||
<property name="fixed_height_mode">False</property>
|
<signal name="button_press_event" handler="on_roster_treeview_button_press_event"/>
|
||||||
<property name="hover_selection">False</property>
|
<signal name="motion_notify_event" handler="on_roster_treeview_motion_notify_event"/>
|
||||||
<property name="hover_expand">False</property>
|
<signal name="row_collapsed" handler="on_roster_treeview_row_collapsed"/>
|
||||||
<signal name="button_press_event" handler="on_roster_treeview_button_press_event" last_modification_time="Mon, 28 Feb 2005 14:16:44 GMT"/>
|
<signal name="row_expanded" handler="on_roster_treeview_row_expanded"/>
|
||||||
<signal name="row_activated" handler="on_roster_treeview_row_activated" last_modification_time="Mon, 28 Feb 2005 14:18:06 GMT"/>
|
<signal name="key_press_event" handler="on_roster_treeview_key_press_event"/>
|
||||||
<signal name="row_expanded" handler="on_roster_treeview_row_expanded" last_modification_time="Mon, 28 Feb 2005 14:18:14 GMT"/>
|
<signal name="row_activated" handler="on_roster_treeview_row_activated"/>
|
||||||
<signal name="row_collapsed" handler="on_roster_treeview_row_collapsed" last_modification_time="Mon, 28 Feb 2005 14:18:33 GMT"/>
|
<signal name="scroll_event" handler="on_roster_treeview_scroll_event"/>
|
||||||
<signal name="key_press_event" handler="on_roster_treeview_key_press_event" last_modification_time="Sat, 26 Mar 2005 20:39:36 GMT"/>
|
<signal name="style_set" handler="on_roster_treeview_style_set"/>
|
||||||
<signal name="motion_notify_event" handler="on_roster_treeview_motion_notify_event" last_modification_time="Wed, 06 Jul 2005 14:38:58 GMT"/>
|
|
||||||
<signal name="leave_notify_event" handler="on_roster_treeview_leave_notify_event" last_modification_time="Wed, 06 Jul 2005 14:39:06 GMT"/>
|
|
||||||
<signal name="scroll_event" handler="on_roster_treeview_scroll_event" last_modification_time="Fri, 08 Jul 2005 22:09:03 GMT"/>
|
|
||||||
<signal name="style_set" handler="on_roster_treeview_style_set" last_modification_time="Tue, 08 Nov 2005 14:03:30 GMT"/>
|
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
<property name="position">1</property>
|
||||||
<property name="expand">True</property>
|
|
||||||
<property name="fill">True</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkComboBox" id="status_combobox">
|
<widget class="GtkComboBox" id="status_combobox">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="add_tearoffs">False</property>
|
<signal name="changed" handler="on_status_combobox_changed"/>
|
||||||
<property name="focus_on_click">True</property>
|
|
||||||
<signal name="changed" handler="on_status_combobox_changed" last_modification_time="Sat, 05 Nov 2005 18:07:49 GMT"/>
|
|
||||||
</widget>
|
</widget>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="fill">True</property>
|
<property name="position">2</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</child>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
|
||||||
</glade-interface>
|
</glade-interface>
|
||||||
|
|
|
@ -46,6 +46,7 @@ VCARD_ARRIVED = 'vcard_arrived'
|
||||||
AGENT_REMOVED = 'agent_removed'
|
AGENT_REMOVED = 'agent_removed'
|
||||||
METACONTACTS_ARRIVED = 'metacontacts_arrived'
|
METACONTACTS_ARRIVED = 'metacontacts_arrived'
|
||||||
PRIVACY_ARRIVED = 'privacy_arrived'
|
PRIVACY_ARRIVED = 'privacy_arrived'
|
||||||
|
PEP_ACCESS_MODEL = 'pep_access_model'
|
||||||
HAS_IDLE = True
|
HAS_IDLE = True
|
||||||
try:
|
try:
|
||||||
import idle
|
import idle
|
||||||
|
@ -1068,6 +1069,15 @@ class ConnectionVcard:
|
||||||
self.get_privacy_list('block')
|
self.get_privacy_list('block')
|
||||||
# Ask metacontacts before roster
|
# Ask metacontacts before roster
|
||||||
self.get_metacontacts()
|
self.get_metacontacts()
|
||||||
|
elif self.awaiting_answers[id][0] == PEP_ACCESS_MODEL:
|
||||||
|
conf = iq_obj.getTag('pubsub').getTag('configure')
|
||||||
|
node = conf.getAttr('node')
|
||||||
|
form_tag = conf.getTag('x', namespace=common.xmpp.NS_DATA)
|
||||||
|
form = common.dataforms.ExtendForm(node=form_tag)
|
||||||
|
for field in form.iter_fields():
|
||||||
|
if field.var == 'pubsub#access_model':
|
||||||
|
self.dispatch('PEP_ACCESS_MODEL', (node, field.value))
|
||||||
|
break
|
||||||
|
|
||||||
del self.awaiting_answers[id]
|
del self.awaiting_answers[id]
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
import xmpp
|
import xmpp
|
||||||
import gajim
|
import gajim
|
||||||
|
import dataforms
|
||||||
|
import connection_handlers
|
||||||
|
|
||||||
class ConnectionPubSub:
|
class ConnectionPubSub:
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
@ -92,3 +94,12 @@ class ConnectionPubSub:
|
||||||
cb(conn, stanza, *args, **kwargs)
|
cb(conn, stanza, *args, **kwargs)
|
||||||
except KeyError:
|
except KeyError:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def request_pb_configuration(self, jid, node):
|
||||||
|
query = xmpp.Iq('get', to=jid)
|
||||||
|
e = query.addChild('pubsub', namespace=xmpp.NS_PUBSUB_OWNER)
|
||||||
|
e = e.addChild('configure', {'node': node})
|
||||||
|
id = self.connection.getAnID()
|
||||||
|
query.setID(id)
|
||||||
|
self.awaiting_answers[id] = (connection_handlers.PEP_ACCESS_MODEL,)
|
||||||
|
self.connection.send(query)
|
||||||
|
|
|
@ -74,6 +74,7 @@ NS_PRIVACY ='jabber:iq:privacy'
|
||||||
NS_PRIVATE ='jabber:iq:private'
|
NS_PRIVATE ='jabber:iq:private'
|
||||||
NS_PROFILE ='http://jabber.org/protocol/profile' # JEP-0154
|
NS_PROFILE ='http://jabber.org/protocol/profile' # JEP-0154
|
||||||
NS_PUBSUB ='http://jabber.org/protocol/pubsub' # JEP-0060
|
NS_PUBSUB ='http://jabber.org/protocol/pubsub' # JEP-0060
|
||||||
|
NS_PUBSUB_OWNER ='http://jabber.org/protocol/pubsub#owner' # JEP-0060
|
||||||
NS_REGISTER ='jabber:iq:register'
|
NS_REGISTER ='jabber:iq:register'
|
||||||
NS_ROSTER ='jabber:iq:roster'
|
NS_ROSTER ='jabber:iq:roster'
|
||||||
NS_ROSTERX ='http://jabber.org/protocol/rosterx' # JEP-0144
|
NS_ROSTERX ='http://jabber.org/protocol/rosterx' # JEP-0144
|
||||||
|
|
|
@ -3360,7 +3360,7 @@ class ZeroconfPropertiesWindow:
|
||||||
|
|
||||||
config['keyname'] = self.xml.get_widget('gpg_name_label').get_text().\
|
config['keyname'] = self.xml.get_widget('gpg_name_label').get_text().\
|
||||||
decode('utf-8')
|
decode('utf-8')
|
||||||
if config['keyname'] == '': #no key selected
|
if config['keyname'] == '': # no key selected
|
||||||
config['keyid'] = ''
|
config['keyid'] = ''
|
||||||
config['savegpgpass'] = False
|
config['savegpgpass'] = False
|
||||||
config['gpgpassword'] = ''
|
config['gpgpassword'] = ''
|
||||||
|
@ -3430,3 +3430,65 @@ class ZeroconfPropertiesWindow:
|
||||||
st = widget.get_active()
|
st = widget.get_active()
|
||||||
w = self.xml.get_widget('gpg_password_entry')
|
w = self.xml.get_widget('gpg_password_entry')
|
||||||
w.set_sensitive(bool(st))
|
w.set_sensitive(bool(st))
|
||||||
|
|
||||||
|
class ManagePEPServicesWindow:
|
||||||
|
def __init__(self, account):
|
||||||
|
self.xml = gtkgui_helpers.get_glade('manage_pep_services_window.glade')
|
||||||
|
self.window = self.xml.get_widget('manage_pep_services_window')
|
||||||
|
self.window.set_transient_for(gajim.interface.roster.window)
|
||||||
|
self.xml.signal_autoconnect(self)
|
||||||
|
self.account = account
|
||||||
|
|
||||||
|
self.init_services()
|
||||||
|
self.window.show_all()
|
||||||
|
|
||||||
|
def on_manage_pep_services_window_destroy(self, widget):
|
||||||
|
'''close window'''
|
||||||
|
del gajim.interface.instances[self.account]['pep_services']
|
||||||
|
|
||||||
|
def cellrenderer_combo_edited(self, cellrenderer, path, new_text):
|
||||||
|
self.treestore[path][1] = new_text
|
||||||
|
|
||||||
|
def init_services(self):
|
||||||
|
treeview = self.xml.get_widget('services_treeview')
|
||||||
|
# service, access_model, group
|
||||||
|
self.treestore = gtk.ListStore(str, str, str)
|
||||||
|
treeview.set_model(self.treestore)
|
||||||
|
|
||||||
|
col = gtk.TreeViewColumn('Service')
|
||||||
|
treeview.append_column(col)
|
||||||
|
|
||||||
|
cellrenderer_text = gtk.CellRendererText()
|
||||||
|
col.pack_start(cellrenderer_text)
|
||||||
|
col.add_attribute(cellrenderer_text, 'text', 0)
|
||||||
|
|
||||||
|
col = gtk.TreeViewColumn('access model')
|
||||||
|
treeview.append_column(col)
|
||||||
|
|
||||||
|
model = gtk.ListStore(str)
|
||||||
|
model.append(['open'])
|
||||||
|
model.append(['presence'])
|
||||||
|
model.append(['roster'])
|
||||||
|
model.append(['whitelist'])
|
||||||
|
cellrenderer_combo = gtk.CellRendererCombo()
|
||||||
|
cellrenderer_combo.set_property('text-column', 0)
|
||||||
|
cellrenderer_combo.set_property('model', model)
|
||||||
|
cellrenderer_combo.set_property('has-entry', False)
|
||||||
|
cellrenderer_combo.set_property('editable', True)
|
||||||
|
cellrenderer_combo.connect('edited', self.cellrenderer_combo_edited)
|
||||||
|
col.pack_start(cellrenderer_combo)
|
||||||
|
col.add_attribute(cellrenderer_combo, 'text', 1)
|
||||||
|
|
||||||
|
our_jid = gajim.get_jid_from_account(self.account)
|
||||||
|
gajim.connections[self.account].discoverItems(our_jid)
|
||||||
|
|
||||||
|
def items_received(self, items):
|
||||||
|
our_jid = gajim.get_jid_from_account(self.account)
|
||||||
|
for item in items:
|
||||||
|
if 'jid' in item and item['jid'] == our_jid and 'node' in item:
|
||||||
|
# ask <configure> to have access model
|
||||||
|
gajim.connections[self.account].request_pb_configuration(
|
||||||
|
item['jid'], item['node'])
|
||||||
|
|
||||||
|
def new_service(self, node, model):
|
||||||
|
self.treestore.append([node, model, ''])
|
||||||
|
|
11
src/gajim.py
11
src/gajim.py
|
@ -934,6 +934,11 @@ class Interface:
|
||||||
|
|
||||||
def handle_event_agent_info_items(self, account, array):
|
def handle_event_agent_info_items(self, account, array):
|
||||||
#('AGENT_INFO_ITEMS', account, (agent, node, items))
|
#('AGENT_INFO_ITEMS', account, (agent, node, items))
|
||||||
|
our_jid = gajim.get_jid_from_account(account)
|
||||||
|
if gajim.interface.instances[account].has_key('pep_services') and \
|
||||||
|
array[0] == our_jid:
|
||||||
|
gajim.interface.instances[account]['pep_services'].items_received(
|
||||||
|
array[2])
|
||||||
try:
|
try:
|
||||||
gajim.connections[account].services_cache.agent_items(array[0],
|
gajim.connections[account].services_cache.agent_items(array[0],
|
||||||
array[1], array[2])
|
array[1], array[2])
|
||||||
|
@ -1776,6 +1781,11 @@ class Interface:
|
||||||
_('You are already connected to this account with the same resource. Please type a new one'), input_str = gajim.connections[account].server_resource,
|
_('You are already connected to this account with the same resource. Please type a new one'), input_str = gajim.connections[account].server_resource,
|
||||||
is_modal = False, ok_handler = on_ok)
|
is_modal = False, ok_handler = on_ok)
|
||||||
|
|
||||||
|
def handle_event_pep_access_model(self, account, data):
|
||||||
|
# ('PEP_ACCESS_MODEL', account, (node, model))
|
||||||
|
if self.instances[account].has_key('pep_services'):
|
||||||
|
self.instances[account]['pep_services'].new_service(data[0], data[1])
|
||||||
|
|
||||||
def read_sleepy(self):
|
def read_sleepy(self):
|
||||||
'''Check idle status and change that status if needed'''
|
'''Check idle status and change that status if needed'''
|
||||||
if not self.sleeper.poll():
|
if not self.sleeper.poll():
|
||||||
|
@ -2102,6 +2112,7 @@ class Interface:
|
||||||
'SEARCH_FORM': self.handle_event_search_form,
|
'SEARCH_FORM': self.handle_event_search_form,
|
||||||
'SEARCH_RESULT': self.handle_event_search_result,
|
'SEARCH_RESULT': self.handle_event_search_result,
|
||||||
'RESOURCE_CONFLICT': self.handle_event_resource_conflict,
|
'RESOURCE_CONFLICT': self.handle_event_resource_conflict,
|
||||||
|
'PEP_ACCESS_MODEL': self.handle_event_pep_access_model,
|
||||||
}
|
}
|
||||||
gajim.handlers = self.handlers
|
gajim.handlers = self.handlers
|
||||||
|
|
||||||
|
|
|
@ -904,6 +904,7 @@ class RosterWindow:
|
||||||
service_disco_menuitem = self.xml.get_widget('service_disco_menuitem')
|
service_disco_menuitem = self.xml.get_widget('service_disco_menuitem')
|
||||||
advanced_menuitem = self.xml.get_widget('advanced_menuitem')
|
advanced_menuitem = self.xml.get_widget('advanced_menuitem')
|
||||||
profile_avatar_menuitem = self.xml.get_widget('profile_avatar_menuitem')
|
profile_avatar_menuitem = self.xml.get_widget('profile_avatar_menuitem')
|
||||||
|
pep_services_menuitem = self.xml.get_widget('pep_services_menuitem')
|
||||||
|
|
||||||
# destroy old advanced menus
|
# destroy old advanced menus
|
||||||
for m in self.advanced_menus:
|
for m in self.advanced_menus:
|
||||||
|
@ -927,10 +928,10 @@ class RosterWindow:
|
||||||
self.new_chat_menuitem_handler_id)
|
self.new_chat_menuitem_handler_id)
|
||||||
self.new_chat_menuitem_handler_id = None
|
self.new_chat_menuitem_handler_id = None
|
||||||
|
|
||||||
if self.profile_avatar_menuitem_handler_id:
|
if self.pep_services_menuitem_handler_id:
|
||||||
profile_avatar_menuitem.handler_disconnect(
|
pep_services_menuitem.handler_disconnect(
|
||||||
self.profile_avatar_menuitem_handler_id)
|
self.pep_services_menuitem_handler_id)
|
||||||
self.profile_avatar_menuitem_handler_id = None
|
self.pep_services_menuitem_handler_id = None
|
||||||
|
|
||||||
|
|
||||||
# remove the existing submenus
|
# remove the existing submenus
|
||||||
|
@ -940,6 +941,7 @@ class RosterWindow:
|
||||||
new_chat_menuitem.remove_submenu()
|
new_chat_menuitem.remove_submenu()
|
||||||
advanced_menuitem.remove_submenu()
|
advanced_menuitem.remove_submenu()
|
||||||
profile_avatar_menuitem.remove_submenu()
|
profile_avatar_menuitem.remove_submenu()
|
||||||
|
pep_services_menuitem.remove_submenu()
|
||||||
|
|
||||||
# remove the existing accelerator
|
# remove the existing accelerator
|
||||||
if self.have_new_chat_accel:
|
if self.have_new_chat_accel:
|
||||||
|
@ -1068,6 +1070,7 @@ class RosterWindow:
|
||||||
if len(connected_accounts_with_vcard) > 1:
|
if len(connected_accounts_with_vcard) > 1:
|
||||||
# 2 or more accounts? make submenus
|
# 2 or more accounts? make submenus
|
||||||
profile_avatar_sub_menu = gtk.Menu()
|
profile_avatar_sub_menu = gtk.Menu()
|
||||||
|
pep_services_sub_menu = gtk.Menu()
|
||||||
for account in connected_accounts_with_vcard:
|
for account in connected_accounts_with_vcard:
|
||||||
# profile, avatar
|
# profile, avatar
|
||||||
profile_avatar_item = gtk.MenuItem(_('of account %s') % account,
|
profile_avatar_item = gtk.MenuItem(_('of account %s') % account,
|
||||||
|
@ -1075,20 +1078,35 @@ class RosterWindow:
|
||||||
profile_avatar_sub_menu.append(profile_avatar_item)
|
profile_avatar_sub_menu.append(profile_avatar_item)
|
||||||
profile_avatar_item.connect('activate',
|
profile_avatar_item.connect('activate',
|
||||||
self.on_profile_avatar_menuitem_activate, account)
|
self.on_profile_avatar_menuitem_activate, account)
|
||||||
|
# PEP services
|
||||||
|
pep_services_item = gtk.MenuItem(_('of account %s') % account,
|
||||||
|
False)
|
||||||
|
pep_services_sub_menu.append(pep_services_item)
|
||||||
|
pep_services_item.connect('activate',
|
||||||
|
self.on_pep_services_menuitem_activate, account)
|
||||||
profile_avatar_menuitem.set_submenu(profile_avatar_sub_menu)
|
profile_avatar_menuitem.set_submenu(profile_avatar_sub_menu)
|
||||||
profile_avatar_sub_menu.show_all()
|
profile_avatar_sub_menu.show_all()
|
||||||
|
pep_services_menuitem.set_submenu(pep_services_sub_menu)
|
||||||
|
pep_services_sub_menu.show_all()
|
||||||
elif len(connected_accounts_with_vcard) == 1: # user has only one account
|
elif len(connected_accounts_with_vcard) == 1: # user has only one account
|
||||||
account = connected_accounts_with_vcard[0]
|
account = connected_accounts_with_vcard[0]
|
||||||
# profile, avatar
|
# profile, avatar
|
||||||
if not self.profile_avatar_menuitem_handler_id:
|
if not self.profile_avatar_menuitem_handler_id:
|
||||||
self.profile_avatar_menuitem_handler_id = \
|
self.profile_avatar_menuitem_handler_id = \
|
||||||
profile_avatar_menuitem.connect('activate', self.\
|
profile_avatar_menuitem.connect('activate',
|
||||||
on_profile_avatar_menuitem_activate, account)
|
self.on_profile_avatar_menuitem_activate, account)
|
||||||
|
# PEP services
|
||||||
|
if not self.pep_services_menuitem_handler_id:
|
||||||
|
self.pep_services_menuitem_handler_id = \
|
||||||
|
pep_services_menuitem.connect('activate',
|
||||||
|
self.on_pep_services_menuitem_activate, account)
|
||||||
|
|
||||||
if len(connected_accounts_with_vcard) == 0:
|
if len(connected_accounts_with_vcard) == 0:
|
||||||
profile_avatar_menuitem.set_sensitive(False)
|
profile_avatar_menuitem.set_sensitive(False)
|
||||||
|
pep_services_menuitem.set_sensitive(False)
|
||||||
else:
|
else:
|
||||||
profile_avatar_menuitem.set_sensitive(True)
|
profile_avatar_menuitem.set_sensitive(True)
|
||||||
|
pep_services_menuitem.set_sensitive(True)
|
||||||
|
|
||||||
newitem = gtk.ImageMenuItem(_('_Manage Bookmarks...'))
|
newitem = gtk.ImageMenuItem(_('_Manage Bookmarks...'))
|
||||||
img = gtk.image_new_from_stock(gtk.STOCK_PREFERENCES,
|
img = gtk.image_new_from_stock(gtk.STOCK_PREFERENCES,
|
||||||
|
@ -3684,6 +3702,13 @@ class RosterWindow:
|
||||||
else:
|
else:
|
||||||
gajim.interface.instances['preferences'] = config.PreferencesWindow()
|
gajim.interface.instances['preferences'] = config.PreferencesWindow()
|
||||||
|
|
||||||
|
def on_pep_services_menuitem_activate(self, widget, account):
|
||||||
|
if gajim.interface.instances[account].has_key('pep_services'):
|
||||||
|
gajim.interface.instances[account]['pep_services'].window.present()
|
||||||
|
else:
|
||||||
|
gajim.interface.instances[account]['pep_services'] = \
|
||||||
|
config.ManagePEPServicesWindow(account)
|
||||||
|
|
||||||
def on_add_new_contact(self, widget, account):
|
def on_add_new_contact(self, widget, account):
|
||||||
dialogs.AddNewContactWindow(account)
|
dialogs.AddNewContactWindow(account)
|
||||||
|
|
||||||
|
@ -4840,6 +4865,7 @@ class RosterWindow:
|
||||||
self.service_disco_handler_id = False
|
self.service_disco_handler_id = False
|
||||||
self.new_chat_menuitem_handler_id = False
|
self.new_chat_menuitem_handler_id = False
|
||||||
self.profile_avatar_menuitem_handler_id = False
|
self.profile_avatar_menuitem_handler_id = False
|
||||||
|
self.pep_services_menuitem_handler_id = False
|
||||||
self.actions_menu_needs_rebuild = True
|
self.actions_menu_needs_rebuild = True
|
||||||
self.regroup = gajim.config.get('mergeaccounts')
|
self.regroup = gajim.config.get('mergeaccounts')
|
||||||
if len(gajim.connections) < 2: # Do not merge accounts if only one exists
|
if len(gajim.connections) < 2: # Do not merge accounts if only one exists
|
||||||
|
|
Loading…
Reference in New Issue