diff options
author | JP Rosevear <jpr@ximian.com> | 2002-01-03 23:01:46 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2002-01-03 23:01:46 +0800 |
commit | 0fe2d5201603163b11341cb3719500fa762bc532 (patch) | |
tree | 3441593f37dc1a3de3bc534fdc969060e6cdf987 /calendar/gui/calendar-config.c | |
parent | c3cc401ac8aee97bd9625ea5d420ce2bf70363bd (diff) | |
download | gsoc2013-evolution-0fe2d5201603163b11341cb3719500fa762bc532.tar.gz gsoc2013-evolution-0fe2d5201603163b11341cb3719500fa762bc532.tar.zst gsoc2013-evolution-0fe2d5201603163b11341cb3719500fa762bc532.zip |
confirm expunging of the tasks (tasks_control_expunge_cmd): verb callback
2002-01-03 JP Rosevear <jpr@ximian.com>
* gui/tasks-control.c (confirm_expunge): confirm expunging of the
tasks
(tasks_control_expunge_cmd): verb callback
* gui/calendar-config.c (config_read): read confirm expunge value
(calendar_config_write): write confirm expunge value
(calendar_config_write_on_exit): ditto
(calendar_config_get_confirm_expunge): get value
(calendar_config_set_confirm_expunge): set value
* gui/calendar-config.h: new proto
* gui/e-itip-control.c (start_calendar_server): kill warning
* gui/e-tasks.c (e_tasks_init): init query member to NULL
(set_status_message): util function to set status message
(e_tasks_open): use above
(cal_opened_cb): ditto
(create_sexp): create sexp of items to be deleted
(query_obj_updated_cb): remove any items found
(query_eval_error_cb): bail out on error
(query_query_done_cb): tidy when done
(e_tasks_delete_completed): set up query
* gui/e-tasks.h: new proto
* gui/calendar-model.c (query_query_done_cb): use g_warning
instead of printing to stderr
(query_eval_error_cb): ditto
(update_query): clear the status message if we can't create the
query
* gui/tag-calendar.c (resolve_tzid_cb): make this static
svn path=/trunk/; revision=15233
Diffstat (limited to 'calendar/gui/calendar-config.c')
-rw-r--r-- | calendar/gui/calendar-config.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/calendar/gui/calendar-config.c b/calendar/gui/calendar-config.c index 57347709a4..e0313fe3a7 100644 --- a/calendar/gui/calendar-config.c +++ b/calendar/gui/calendar-config.c @@ -70,6 +70,7 @@ typedef struct CalUnits hide_completed_tasks_units; gint hide_completed_tasks_value; gboolean confirm_delete; + gboolean confirm_expunge; gboolean use_default_reminder; int default_reminder_interval; CalUnits default_reminder_units; @@ -246,6 +247,8 @@ config_read (void) /* Confirmation */ config->confirm_delete = bonobo_config_get_boolean_with_default ( db, "/Calendar/Other/ConfirmDelete", TRUE, NULL); + config->confirm_expunge = bonobo_config_get_boolean_with_default ( + db, "/Calendar/Other/ConfirmExpunge", TRUE, NULL); /* Default reminders */ config->use_default_reminder = bonobo_config_get_boolean_with_default ( @@ -358,6 +361,7 @@ calendar_config_write (void) config->hide_completed_tasks_value, NULL); bonobo_config_set_boolean (db, "/Calendar/Other/ConfirmDelete", config->confirm_delete, NULL); + bonobo_config_set_boolean (db, "/Calendar/Other/ConfirmExpunge", config->confirm_expunge, NULL); bonobo_config_set_boolean (db, "/Calendar/Other/UseDefaultReminder", config->use_default_reminder, NULL); @@ -403,6 +407,9 @@ calendar_config_write_on_exit (void) bonobo_config_set_float (db, "/Calendar/Display/MonthVPanePosition", config->month_vpane_pos, NULL); + bonobo_config_set_boolean (db, "/Calendar/Other/ConfirmExpunge", + config->confirm_expunge, NULL); + Bonobo_ConfigDatabase_sync (db, &ev); bonobo_object_release_unref (db, NULL); @@ -798,6 +805,32 @@ calendar_config_set_confirm_delete (gboolean confirm) config->confirm_delete = confirm; } +/** + * calendar_config_get_confirm_expunge: + * + * Queries the configuration value for whether a confirmation dialog is + * presented when expunging calendar/tasks items. + * + * Return value: Whether confirmation is required when expunging items. + **/ +gboolean +calendar_config_get_confirm_expunge (void) +{ + return config->confirm_expunge; +} + +/** + * calendar_config_set_confirm_expunge: + * @confirm: Whether confirmation is required when expunging items. + * + * Sets the configuration value for whether a confirmation dialog is presented + * when expunging calendar/tasks items. + **/ +void +calendar_config_set_confirm_expunge (gboolean confirm) +{ + config->confirm_expunge = confirm; +} /* This sets all the common config settings for an ECalendar widget. These are the week start day, and whether we show week numbers. */ |