aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2009-11-17 01:51:42 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2009-11-23 23:06:37 +0800
commit8c92880ac4be339e9047cb03f981c7ec5de9cbfb (patch)
tree665f293976b14298bcb58af5573bb0dd28277e93 /libempathy-gtk
parentaa9f5c39b0600d7cba3d63124d8d7018e63209f1 (diff)
downloadgsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar.gz
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar.bz2
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar.lz
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar.xz
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.tar.zst
gsoc2013-empathy-8c92880ac4be339e9047cb03f981c7ec5de9cbfb.zip
account-widget-sip: add UI to configure the keepalive-mechanism and keepalive-interval params
Diffstat (limited to 'libempathy-gtk')
-rw-r--r--libempathy-gtk/empathy-account-widget-sip.c22
-rw-r--r--libempathy-gtk/empathy-account-widget-sip.ui46
2 files changed, 67 insertions, 1 deletions
diff --git a/libempathy-gtk/empathy-account-widget-sip.c b/libempathy-gtk/empathy-account-widget-sip.c
index 3a50ceda7..fba053f33 100644
--- a/libempathy-gtk/empathy-account-widget-sip.c
+++ b/libempathy-gtk/empathy-account-widget-sip.c
@@ -43,6 +43,7 @@ typedef struct {
GtkWidget *spinbutton_stun_part;
GtkWidget *checkbutton_discover_stun;
GtkWidget *combobox_transport;
+ GtkWidget *combobox_keep_alive_mechanism;
} EmpathyAccountWidgetSip;
static void
@@ -115,6 +116,7 @@ empathy_account_widget_sip_build (EmpathyAccountWidget *self,
"spinbutton_port", "port",
"checkbutton_loose-routing", "loose-routing",
"checkbutton_discover-binding", "discover-binding",
+ "spinbutton_keepalive-interval", "keepalive-interval",
NULL);
account_widget_sip_discover_stun_toggled_cb (
@@ -150,6 +152,26 @@ empathy_account_widget_sip_build (EmpathyAccountWidget *self,
settings->combobox_transport, 1, 2, 6, 7);
gtk_widget_show (settings->combobox_transport);
+
+ /* Create the 'keep-alive mechanism' combo box */
+ settings->combobox_keep_alive_mechanism = gtk_combo_box_new_text ();
+
+ gtk_combo_box_append_text (
+ GTK_COMBO_BOX (settings->combobox_keep_alive_mechanism), "auto");
+ gtk_combo_box_append_text (
+ GTK_COMBO_BOX (settings->combobox_keep_alive_mechanism), "register");
+ gtk_combo_box_append_text (
+ GTK_COMBO_BOX (settings->combobox_keep_alive_mechanism), "options");
+ gtk_combo_box_append_text (
+ GTK_COMBO_BOX (settings->combobox_keep_alive_mechanism), "none");
+
+ account_widget_setup_widget (self,
+ settings->combobox_keep_alive_mechanism, "keepalive-mechanism");
+
+ gtk_table_attach_defaults (GTK_TABLE (table_advanced),
+ settings->combobox_keep_alive_mechanism, 1, 2, 9, 10);
+
+ gtk_widget_show (settings->combobox_keep_alive_mechanism);
}
self->ui_details->widget = vbox_settings;
diff --git a/libempathy-gtk/empathy-account-widget-sip.ui b/libempathy-gtk/empathy-account-widget-sip.ui
index 6471d9c04..1bfeafe5c 100644
--- a/libempathy-gtk/empathy-account-widget-sip.ui
+++ b/libempathy-gtk/empathy-account-widget-sip.ui
@@ -134,7 +134,7 @@
<child>
<object class="GtkTable" id="table_advanced_sip_settings">
<property name="visible">True</property>
- <property name="n_rows">9</property>
+ <property name="n_rows">11</property>
<property name="n_columns">2</property>
<property name="column_spacing">6</property>
<property name="row_spacing">6</property>
@@ -329,8 +329,47 @@ username.</property>
</packing>
</child>
<child>
+ <object class="GtkLabel" id="label_keepalive-mechanism">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Keep-alive Mechanism:</property>
+ </object>
+ <packing>
+ <property name="top_attach">9</property>
+ <property name="bottom_attach">10</property>
+ </packing>
+ </child>
+ <child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label_keepalive-interval">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Keep-alive Interval (seconds)</property>
+ </object>
+ <packing>
+ <property name="top_attach">10</property>
+ <property name="bottom_attach">11</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="spinbutton_keepalive-interval">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="adjustment">adjustment3</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">10</property>
+ <property name="bottom_attach">11</property>
+ </packing>
+ </child>
</object>
</child>
</object>
@@ -445,4 +484,9 @@ username.</property>
<property name="step_increment">1</property>
<property name="page_increment">10</property>
</object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
</interface>