diff options
author | Xavier Claessens <xclaesse@src.gnome.org> | 2008-04-02 20:56:23 +0800 |
---|---|---|
committer | Xavier Claessens <xclaesse@src.gnome.org> | 2008-04-02 20:56:23 +0800 |
commit | 094b72ebfbcc324f980378278e19206b20d5d15e (patch) | |
tree | 6da4fd4286c5f3f1a31c56b920180f1f441ce7c5 | |
parent | fd3fa32bca7a915619aec8af502b02d2b012b826 (diff) | |
download | gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar.gz gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar.bz2 gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar.lz gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar.xz gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.tar.zst gsoc2013-empathy-094b72ebfbcc324f980378278e19206b20d5d15e.zip |
Add a widget to configure AIM accounts. Fixes bug #513676 (Andreas Henriksson).
svn path=/trunk/; revision=860
-rw-r--r-- | data/aim.profile | 2 | ||||
-rw-r--r-- | libempathy-gtk/Makefile.am | 1 | ||||
-rw-r--r-- | libempathy-gtk/empathy-account-widget-aim.glade | 193 | ||||
-rw-r--r-- | libempathy-gtk/empathy-account-widget.c | 36 | ||||
-rw-r--r-- | libempathy-gtk/empathy-account-widget.h | 1 | ||||
-rw-r--r-- | libempathy-gtk/empathy-accounts-dialog.c | 4 |
6 files changed, 236 insertions, 1 deletions
diff --git a/data/aim.profile b/data/aim.profile index d92d1b2cd..ae7dbaecc 100644 --- a/data/aim.profile +++ b/data/aim.profile @@ -3,7 +3,7 @@ Manager=haze Protocol=aim IconName = im-aim DisplayName=AIM -ConfigurationUI = haze +ConfigurationUI = aim Capabilities = chat-p2p, supports-alias, supports-avatars, supports-roster VCardDefault = 1 VCardField = X-AIM diff --git a/libempathy-gtk/Makefile.am b/libempathy-gtk/Makefile.am index b0849d6e2..9d31ac4f3 100644 --- a/libempathy-gtk/Makefile.am +++ b/libempathy-gtk/Makefile.am @@ -112,6 +112,7 @@ glade_DATA = \ empathy-account-widget-icq.glade \ empathy-account-widget-yahoo.glade \ empathy-account-widget-groupwise.glade \ + empathy-account-widget-aim.glade \ empathy-spell-dialog.glade \ empathy-log-window.glade \ empathy-chat.glade \ diff --git a/libempathy-gtk/empathy-account-widget-aim.glade b/libempathy-gtk/empathy-account-widget-aim.glade new file mode 100644 index 000000000..2f8e2bd94 --- /dev/null +++ b/libempathy-gtk/empathy-account-widget-aim.glade @@ -0,0 +1,193 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd"> +<!--*- mode: xml -*--> +<glade-interface> + <widget class="GtkWindow" id="account_aim_settings"> + <property name="visible">True</property> + <property name="title" translatable="yes">ICQ account settings</property> + <property name="resizable">False</property> + <child> + <widget class="GtkVBox" id="vbox_aim_settings"> + <property name="visible">True</property> + <property name="spacing">6</property> + <child> + <widget class="GtkTable" id="table_common_settings"> + <property name="visible">True</property> + <property name="n_rows">2</property> + <property name="n_columns">3</property> + <property name="column_spacing">12</property> + <property name="row_spacing">6</property> + <child> + <widget class="GtkLabel" id="label_password"> + <property name="visible">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">Pass_word:</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">entry_password</property> + </widget> + <packing> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="x_options">GTK_FILL</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkLabel" id="label_screenname"> + <property name="visible">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">Screen _Name:</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">entry_uin</property> + </widget> + <packing> + <property name="x_options">GTK_FILL</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkButton" id="button_forget"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="tooltip" translatable="yes">Forget password and clear the entry.</property> + <property name="response_id">0</property> + <child> + <widget class="GtkImage" id="image834"> + <property name="visible">True</property> + <property name="stock">gtk-clear</property> + <property name="icon_size">1</property> + </widget> + </child> + </widget> + <packing> + <property name="left_attach">2</property> + <property name="right_attach">3</property> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="x_options"></property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkEntry" id="entry_uin"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="invisible_char">*</property> + </widget> + <packing> + <property name="left_attach">1</property> + <property name="right_attach">3</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkEntry" id="entry_password"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="visibility">False</property> + <property name="invisible_char">*</property> + </widget> + <packing> + <property name="left_attach">1</property> + <property name="right_attach">2</property> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="y_options"></property> + </packing> + </child> + </widget> + <packing> + <property name="expand">False</property> + <property name="fill">False</property> + </packing> + </child> + <child> + <widget class="GtkExpander" id="expander1"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <child> + <widget class="GtkTable" id="table_advanced_settings"> + <property name="visible">True</property> + <property name="n_rows">2</property> + <property name="n_columns">2</property> + <property name="column_spacing">12</property> + <property name="row_spacing">6</property> + <child> + <widget class="GtkSpinButton" id="spinbutton_port"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="adjustment">5222 0 65556 1 10 10</property> + <property name="climb_rate">1</property> + <property name="numeric">True</property> + </widget> + <packing> + <property name="left_attach">1</property> + <property name="right_attach">2</property> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkLabel" id="label_port"> + <property name="visible">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Port:</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">spinbutton_port</property> + </widget> + <packing> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="x_options">GTK_FILL</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkEntry" id="entry_server"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="invisible_char">*</property> + </widget> + <packing> + <property name="left_attach">1</property> + <property name="right_attach">2</property> + <property name="y_options"></property> + </packing> + </child> + <child> + <widget class="GtkLabel" id="label_server"> + <property name="visible">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Server:</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">entry_server</property> + </widget> + <packing> + <property name="x_options">GTK_FILL</property> + <property name="y_options"></property> + </packing> + </child> + </widget> + </child> + <child> + <widget class="GtkLabel" id="label1"> + <property name="visible">True</property> + <property name="label" translatable="yes"><b>Advanced</b></property> + <property name="use_markup">True</property> + </widget> + <packing> + <property name="type">label_item</property> + </packing> + </child> + </widget> + <packing> + <property name="expand">False</property> + <property name="fill">False</property> + <property name="position">1</property> + </packing> + </child> + </widget> + </child> + </widget> +</glade-interface> diff --git a/libempathy-gtk/empathy-account-widget.c b/libempathy-gtk/empathy-account-widget.c index 4550e9ec3..88cb509c1 100644 --- a/libempathy-gtk/empathy-account-widget.c +++ b/libempathy-gtk/empathy-account-widget.c @@ -671,6 +671,42 @@ empathy_account_widget_icq_new (McAccount *account) } GtkWidget * +empathy_account_widget_aim_new (McAccount *account) +{ + GladeXML *glade; + GtkWidget *widget; + GtkWidget *spinbutton_port; + gchar *filename; + + filename = empathy_file_lookup ("empathy-account-widget-aim.glade", + "libempathy-gtk"); + glade = empathy_glade_get_file (filename, + "vbox_aim_settings", + NULL, + "vbox_aim_settings", &widget, + "spinbutton_port", &spinbutton_port, + NULL); + g_free (filename); + + empathy_account_widget_handle_params (account, glade, + "entry_screenname", "account", + "entry_password", "password", + "entry_server", "server", + "spinbutton_port", "port", + NULL); + + empathy_account_widget_add_forget_button (account, glade, + "button_forget", + "entry_password"); + + g_object_unref (glade); + + gtk_widget_show (widget); + + return widget; +} + +GtkWidget * empathy_account_widget_yahoo_new (McAccount *account) { GladeXML *glade; diff --git a/libempathy-gtk/empathy-account-widget.h b/libempathy-gtk/empathy-account-widget.h index 5c5940fab..d477c1393 100644 --- a/libempathy-gtk/empathy-account-widget.h +++ b/libempathy-gtk/empathy-account-widget.h @@ -45,6 +45,7 @@ GtkWidget *empathy_account_widget_salut_new (McAccount *account); GtkWidget *empathy_account_widget_msn_new (McAccount *account); GtkWidget *empathy_account_widget_jabber_new (McAccount *account); GtkWidget *empathy_account_widget_icq_new (McAccount *account); +GtkWidget *empathy_account_widget_aim_new (McAccount *account); GtkWidget *empathy_account_widget_yahoo_new (McAccount *account); GtkWidget *empathy_account_widget_sip_new (McAccount *account); GtkWidget *empathy_account_widget_groupwise_new (McAccount *account); diff --git a/libempathy-gtk/empathy-accounts-dialog.c b/libempathy-gtk/empathy-accounts-dialog.c index 784bd2b2c..958d709ab 100644 --- a/libempathy-gtk/empathy-accounts-dialog.c +++ b/libempathy-gtk/empathy-accounts-dialog.c @@ -277,6 +277,10 @@ accounts_dialog_update_account (EmpathyAccountsDialog *dialog, dialog->settings_widget = empathy_account_widget_icq_new (account); } + else if (!tp_strdiff(config_ui, "aim")) { + dialog->settings_widget = + empathy_account_widget_aim_new (account); + } else if (!tp_strdiff (config_ui, "yahoo")) { dialog->settings_widget = empathy_account_widget_yahoo_new (account); |