diff options
author | Milan Crha <mcrha@redhat.com> | 2010-12-17 01:04:52 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2010-12-17 01:04:52 +0800 |
commit | 5fd00f91ed46f9964032207c9797a348d2b6ca32 (patch) | |
tree | 4c2d3d34b3205dc42bcd4b13b5efb96ae5d4aa8d /calendar/gui/alarm-notify/config-data.h | |
parent | 27af441d1f0ca1dcbca0175cbfbf99f6482bb743 (diff) | |
download | gsoc2013-evolution-5fd00f91ed46f9964032207c9797a348d2b6ca32.tar.gz gsoc2013-evolution-5fd00f91ed46f9964032207c9797a348d2b6ca32.tar.zst gsoc2013-evolution-5fd00f91ed46f9964032207c9797a348d2b6ca32.zip |
Enable debugging of alarm-notify with ALARMS_DEBUG=1 environment variable
Diffstat (limited to 'calendar/gui/alarm-notify/config-data.h')
-rw-r--r-- | calendar/gui/alarm-notify/config-data.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/calendar/gui/alarm-notify/config-data.h b/calendar/gui/alarm-notify/config-data.h index 08f3915b83..e956f508a0 100644 --- a/calendar/gui/alarm-notify/config-data.h +++ b/calendar/gui/alarm-notify/config-data.h @@ -44,4 +44,18 @@ gboolean config_data_is_blessed_program (const gchar *program); ESourceList *config_data_get_calendars (const gchar *); void config_data_replace_string_list (const gchar *, const gchar *, const gchar *); +void config_data_init_debugging (void); +gboolean config_data_start_debugging (void); +void config_data_stop_debugging (void); + +#define debug(x) G_STMT_START { \ + if (config_data_start_debugging ()) { \ + g_print ("%s (%s): ", G_STRFUNC, G_STRLOC); \ + g_print x ; \ + g_print ("\n"); \ + \ + config_data_stop_debugging (); \ + } \ + } G_STMT_END + #endif |