aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-07-15 15:46:02 -0500
committerTed Gould <ted@gould.cx>2010-07-15 15:46:02 -0500
commit8fb0d0bf48f4cdc374683ed207df16c02a0fa756 (patch)
treec95ba513e6cb6850338ddc692daf0caef5285934 /src
parent6d7a5eeb4c4d91ae4490b27d13c6bad39098486d (diff)
downloadayatana-indicator-datetime-8fb0d0bf48f4cdc374683ed207df16c02a0fa756.tar.gz
ayatana-indicator-datetime-8fb0d0bf48f4cdc374683ed207df16c02a0fa756.tar.bz2
ayatana-indicator-datetime-8fb0d0bf48f4cdc374683ed207df16c02a0fa756.zip
Binding the properties into the settings database.
Diffstat (limited to 'src')
-rw-r--r--src/indicator-datetime.c28
1 files changed, 24 insertions, 4 deletions
diff --git a/src/indicator-datetime.c b/src/indicator-datetime.c
index 500f091..de0edb7 100644
--- a/src/indicator-datetime.c
+++ b/src/indicator-datetime.c
@@ -93,10 +93,10 @@ enum {
#define PROP_CUSTOM_TIME_FORMAT_S "custom-time-format"
#define SETTINGS_INTERFACE "org.ayatana.indicator.datetime"
-#define SETTINGS_TIME_FORMAT "time-format"
-#define SETTINGS_SHOW_SECONDS "show-seconds"
-#define SETTINGS_SHOW_DAY "show-day"
-#define SETTINGS_SHOW_DATE "show-date"
+#define SETTINGS_TIME_FORMAT_S "time-format"
+#define SETTINGS_SHOW_SECONDS_S "show-seconds"
+#define SETTINGS_SHOW_DAY_S "show-day"
+#define SETTINGS_SHOW_DATE_S "show-date"
#define SETTINGS_CUSTOM_TIME_FORMAT_S "custom-time-format"
enum {
@@ -208,6 +208,26 @@ indicator_datetime_init (IndicatorDatetime *self)
self->priv->settings = g_settings_new(SETTINGS_INTERFACE);
if (self->priv->settings != NULL) {
g_settings_bind(self->priv->settings,
+ SETTINGS_TIME_FORMAT_S,
+ self,
+ PROP_TIME_FORMAT_S,
+ G_SETTINGS_BIND_DEFAULT);
+ g_settings_bind(self->priv->settings,
+ SETTINGS_SHOW_SECONDS_S,
+ self,
+ PROP_SHOW_SECONDS_S,
+ G_SETTINGS_BIND_DEFAULT);
+ g_settings_bind(self->priv->settings,
+ SETTINGS_SHOW_DAY_S,
+ self,
+ PROP_SHOW_DAY_S,
+ G_SETTINGS_BIND_DEFAULT);
+ g_settings_bind(self->priv->settings,
+ SETTINGS_SHOW_DATE_S,
+ self,
+ PROP_SHOW_DATE_S,
+ G_SETTINGS_BIND_DEFAULT);
+ g_settings_bind(self->priv->settings,
SETTINGS_CUSTOM_TIME_FORMAT_S,
self,
PROP_CUSTOM_TIME_FORMAT_S,