diff options
author | 8 <jpr@ximian.com> | 2003-11-19 11:55:31 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2003-11-19 11:55:31 +0800 |
commit | 28aef9afc71eb2d2606171bbc94d72dfa325ed07 (patch) | |
tree | 8e04efa4dc84d2f67f607f7667127a9d45f22633 /calendar/gui/calendar-config.c | |
parent | 2fc9309f2aa4bc82ca97b10a4206170c69411754 (diff) | |
download | gsoc2013-evolution-28aef9afc71eb2d2606171bbc94d72dfa325ed07.tar.gz gsoc2013-evolution-28aef9afc71eb2d2606171bbc94d72dfa325ed07.tar.zst gsoc2013-evolution-28aef9afc71eb2d2606171bbc94d72dfa325ed07.zip |
add protos
2003-11-18 <jpr@ximian.com>
* gui/calendar-config.h: add protos
* gui/calendar-config.c (calendar_config_get_primary_calendar):
get the primary calendar
(calendar_config_set_primary_calendar): set it
(calendar_config_add_notification_primary_calendar): set
notifications for it
(calendar_config_get_primary_tasks): get the primary task list
(calendar_config_set_primary_tasks): set it
(calendar_config_add_notification_primary_tasks): set
notifications for it
* gui/calendar-config-keys.h: add primary keys
* gui/calendar-component.c (find_first_source): find any source
(update_uri_for_primary_selection): set the default uri and save
the source uid
(update_primary_selection): set the primary selection
(primary_source_selection_changed_cb): use above
(impl_createControls): set the primary selection
* gui/tasks-component.c: as above
svn path=/trunk/; revision=23434
Diffstat (limited to 'calendar/gui/calendar-config.c')
-rw-r--r-- | calendar/gui/calendar-config.c | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/calendar/gui/calendar-config.c b/calendar/gui/calendar-config.c index 913af4acbc..3c12c381ac 100644 --- a/calendar/gui/calendar-config.c +++ b/calendar/gui/calendar-config.c @@ -119,6 +119,7 @@ units_to_string (CalUnits units) * Calendar Settings. */ +/* The current list of calendars selected */ GSList * calendar_config_get_calendars_selected (void) { @@ -141,6 +142,31 @@ calendar_config_add_notification_calendars_selected (GConfClientNotifyFunc func, return id; } +/* The primary calendar */ +char * +calendar_config_get_primary_calendar (void) +{ + return gconf_client_get_string (config, CALENDAR_CONFIG_PRIMARY_CALENDAR, NULL); +} + +void +calendar_config_set_primary_calendar (const char *primary_uid) +{ + gconf_client_set_string (config, CALENDAR_CONFIG_PRIMARY_CALENDAR, primary_uid, NULL); +} + + +guint +calendar_config_add_notification_primary_calendar (GConfClientNotifyFunc func, gpointer data) +{ + guint id; + + id = gconf_client_notify_add (config, CALENDAR_CONFIG_PRIMARY_CALENDAR, func, data, NULL, NULL); + + return id; +} + + /* The current timezone, e.g. "Europe/London". It may be NULL, in which case you should assume UTC (though Evolution will show the timezone-setting dialog the next time a calendar or task folder is selected). */ @@ -463,6 +489,30 @@ calendar_config_add_notification_tasks_selected (GConfClientNotifyFunc func, gpo return id; } +/* The primary task list */ +char * +calendar_config_get_primary_tasks (void) +{ + return gconf_client_get_string (config, CALENDAR_CONFIG_PRIMARY_TASKS, NULL); +} + +void +calendar_config_set_primary_tasks (const char *primary_uid) +{ + gconf_client_set_string (config, CALENDAR_CONFIG_PRIMARY_TASKS, primary_uid, NULL); +} + + +guint +calendar_config_add_notification_primary_tasks (GConfClientNotifyFunc func, gpointer data) +{ + guint id; + + id = gconf_client_notify_add (config, CALENDAR_CONFIG_PRIMARY_TASKS, func, data, NULL, NULL); + + return id; +} + gint calendar_config_get_task_vpane_pos (void) { |