aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-02-11 23:47:53 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-02-12 00:01:38 +0800
commit6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f (patch)
tree5db94e396fb4c29ee6975cf027e6e78ba5801f6b /libempathy-gtk
parent9be6f0a2e28b9719bceafbd95ed49d27363b33c0 (diff)
downloadgsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar.gz
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar.bz2
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar.lz
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar.xz
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.tar.zst
gsoc2013-empathy-6d2a11ac6fa575de2a4ed9e5f9fe239c2063e07f.zip
add a simple version of the Facebook widget
Diffstat (limited to 'libempathy-gtk')
-rw-r--r--libempathy-gtk/empathy-account-widget-jabber.ui93
-rw-r--r--libempathy-gtk/empathy-account-widget.c17
2 files changed, 109 insertions, 1 deletions
diff --git a/libempathy-gtk/empathy-account-widget-jabber.ui b/libempathy-gtk/empathy-account-widget-jabber.ui
index 1e88cf156..e69c08221 100644
--- a/libempathy-gtk/empathy-account-widget-jabber.ui
+++ b/libempathy-gtk/empathy-account-widget-jabber.ui
@@ -616,4 +616,97 @@ Use &lt;a href="http://www.facebook.com/username/"&gt;this page&lt;/a&gt; to def
</packing>
</child>
</object>
+ <object class="GtkVBox" id="vbox_fb_simple">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label_id_fb_simple">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">What is your Facebook ID?</property>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment_simple_fb_id">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">0.34999999403953552</property>
+ <property name="yscale">0.34999999403953552</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">3</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox2">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">4</property>
+ <child>
+ <object class="GtkEntry" id="entry_id_fb_simple">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">&#x2022;</property>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label_fb_example">
+ <property name="visible">True</property>
+ <property name="xalign">0.10000000149011612</property>
+ <property name="label" translatable="yes">If you are http://facebook.com/badger, enter badger.
+Use &lt;a href="http://www.facebook.com/username/"&gt;this page&lt;/a&gt; to define your Facebook alias.</property>
+ <property name="use_markup">True</property>
+ <attributes>
+ <attribute name="scale" value="0.8"/><!-- PANGO_SCALE_SMALL -->
+ </attributes>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label_password_fb_simple">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="ypad">6</property>
+ <property name="label" translatable="yes">What is your Facebook password?</property>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment3">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">0.34999999403953552</property>
+ <property name="yscale">0.5</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkEntry" id="entry_password_fb_simple">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="visibility">False</property>
+ <property name="invisible_char">&#x2022;</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ </object>
</interface>
diff --git a/libempathy-gtk/empathy-account-widget.c b/libempathy-gtk/empathy-account-widget.c
index 0469f6205..4124388d8 100644
--- a/libempathy-gtk/empathy-account-widget.c
+++ b/libempathy-gtk/empathy-account-widget.c
@@ -1069,7 +1069,22 @@ account_widget_build_jabber (EmpathyAccountWidget *self,
self->ui_details->default_focus = g_strdup ("entry_id_g_simple");
}
- /* TODO: Simple widget for Facebook */
+ else if (priv->simple && is_facebook)
+ {
+ /* Simple widget for Facebook */
+ self->ui_details->gui = empathy_builder_get_file (filename,
+ "vbox_fb_simple", &self->ui_details->widget,
+ "entry_id_fb_simple", &entry_id,
+ NULL);
+
+ empathy_account_widget_handle_params (self,
+ "entry_password_fb_simple", "password",
+ NULL);
+
+ setup_facebook_id_widget (self, entry_id);
+
+ self->ui_details->default_focus = g_strdup ("entry_id_fb_simple");
+ }
else
{
/* Full widget for XMPP, Google Talk and Facebook*/