aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/component/addressbook-config.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2008-08-08 12:26:12 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-08-08 12:26:12 +0800
commitcea054cd54d84479352a43bbabc19c9ce9af5efb (patch)
treeba02763209ba0f22989024004f57689071603ec5 /addressbook/gui/component/addressbook-config.c
parent91a6b6899e5568ed34f913bedb538dd6c9e35b32 (diff)
downloadgsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar.gz
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar.bz2
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar.lz
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar.xz
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.tar.zst
gsoc2013-evolution-cea054cd54d84479352a43bbabc19c9ce9af5efb.zip
Merge revisions 35747:35930 from trunk.
svn path=/branches/kill-bonobo/; revision=35931
Diffstat (limited to 'addressbook/gui/component/addressbook-config.c')
-rw-r--r--addressbook/gui/component/addressbook-config.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/addressbook/gui/component/addressbook-config.c b/addressbook/gui/component/addressbook-config.c
index 76b5dca5c1..2b749a6dd8 100644
--- a/addressbook/gui/component/addressbook-config.c
+++ b/addressbook/gui/component/addressbook-config.c
@@ -111,6 +111,7 @@ struct _AddressbookSourceDialog {
GtkWidget *search_filter;
GtkWidget *timeout_scale;
GtkWidget *limit_spinbutton;
+ GtkWidget *canbrowsecheck;
/* display name page fields */
GtkWidget *display_name;
@@ -925,6 +926,15 @@ limit_changed_cb(GtkWidget *w, AddressbookSourceDialog *sdialog)
e_source_set_property(sdialog->source, "limit", limit);
}
+static void
+canbrowse_toggled_cb (GtkWidget *toggle_button, ESource *source)
+{
+ if (!source || !toggle_button)
+ return;
+
+ e_source_set_property (source, "can-browse", gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle_button)) ? "1" : NULL);
+}
+
static GtkWidget *
eabc_details_limit(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, struct _GtkWidget *old, void *data)
{
@@ -956,6 +966,10 @@ eabc_details_limit(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, st
gtk_spin_button_set_value((GtkSpinButton *)sdialog->limit_spinbutton, tmp?g_strtod(tmp, NULL):100.0);
g_signal_connect (sdialog->limit_spinbutton, "value_changed", G_CALLBACK (limit_changed_cb), sdialog);
+ sdialog->canbrowsecheck = glade_xml_get_widget (gui, "canbrowsecheck");
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (sdialog->canbrowsecheck), e_source_get_property (sdialog->source, "can-browse") && strcmp (e_source_get_property (sdialog->source, "can-browse"), "1") == 0);
+ g_signal_connect (sdialog->canbrowsecheck, "toggled", G_CALLBACK (canbrowse_toggled_cb), sdialog->source);
+
g_object_unref(gui);
return w;