aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/main.c
diff options
context:
space:
mode:
authorRussell Steinthal <steintr@src.gnome.org>1999-12-03 08:55:01 +0800
committerRussell Steinthal <steintr@src.gnome.org>1999-12-03 08:55:01 +0800
commitafb45991801e0496d1f177ee5c973bca980ceef3 (patch)
treecab5dce5bbcd84be3299390f7edc66d0f265973e /calendar/gui/main.c
parentaea33f51dd45886be8dd22970e2e6f36ef9a25d6 (diff)
downloadgsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar.gz
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar.bz2
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar.lz
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar.xz
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.tar.zst
gsoc2013-evolution-afb45991801e0496d1f177ee5c973bca980ceef3.zip
The long-awaited and much-needed (IMNSHO) snooze button for gnomecal alarms.
Not strictly [vi]Calendar compliant, but much more intuitive. svn path=/trunk/; revision=1456
Diffstat (limited to 'calendar/gui/main.c')
-rw-r--r--calendar/gui/main.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/calendar/gui/main.c b/calendar/gui/main.c
index 4aef2b7dc6..98157d101d 100644
--- a/calendar/gui/main.c
+++ b/calendar/gui/main.c
@@ -93,6 +93,9 @@ gboolean beep_on_display = 0;
gboolean enable_aalarm_timeout = 0;
guint audio_alarm_timeout = 0;
const guint MAX_AALARM_TIMEOUT = 3600;
+const guint MAX_SNOOZE_SECS = 3600;
+gboolean enable_snooze = 0;
+guint snooze_secs = 60;
/* Default values for alarms */
CalendarAlarm alarm_defaults[4] = {
@@ -231,6 +234,13 @@ init_calendar (void)
audio_alarm_timeout = 1;
if (audio_alarm_timeout > MAX_AALARM_TIMEOUT)
audio_alarm_timeout = MAX_AALARM_TIMEOUT;
+ enable_snooze = gnome_config_get_bool ("/calendar/alarms/enable_snooze=FALSE");
+ snooze_secs = gnome_config_get_int ("/calendar/alarms/snooze_secs=300");
+ if (snooze_secs < 1)
+ snooze_secs = 1;
+ if (snooze_secs > MAX_SNOOZE_SECS)
+ snooze_secs = MAX_SNOOZE_SECS;
+
init_default_alarms ();