diff options
author | Marcel Stimberg <marcelcoding@googlemail.com> | 2009-05-04 12:40:55 +0800 |
---|---|---|
committer | Bharath Acharya <abharath@novell.com> | 2009-05-04 12:40:55 +0800 |
commit | 6e72a236dcb592a942881e118d6a71888ea1581b (patch) | |
tree | c4c3c8a45aa257efd819dea3a59c14c9c0b117b7 /plugins | |
parent | fad86a267fd3c0ebc402ca67f14a0d2f74f57b74 (diff) | |
download | gsoc2013-evolution-6e72a236dcb592a942881e118d6a71888ea1581b.tar.gz gsoc2013-evolution-6e72a236dcb592a942881e118d6a71888ea1581b.tar.zst gsoc2013-evolution-6e72a236dcb592a942881e118d6a71888ea1581b.zip |
** BUGFIX: 573830 - g_timeout_add_seconds should be preferred to g_timeout_add
According to https://wiki.ubuntu.com/SavingTheWorld (and of course according to
the gtk docs) using g_timeout_add_seconds is preferred over g_timeout_add if a
timeout in seconds is desired.
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/bbdb/bbdb.c | 2 | ||||
-rw-r--r-- | plugins/bbdb/bbdb.h | 2 | ||||
-rw-r--r-- | plugins/publish-calendar/publish-calendar.c | 8 |
3 files changed, 6 insertions, 6 deletions
diff --git a/plugins/bbdb/bbdb.c b/plugins/bbdb/bbdb.c index 547a779961..adc89dbcb2 100644 --- a/plugins/bbdb/bbdb.c +++ b/plugins/bbdb/bbdb.c @@ -115,7 +115,7 @@ e_plugin_lib_enable (EPluginLib *ep, int enable) if (bbdb_check_gaim_enabled ()) bbdb_sync_buddy_list_check (); - g_timeout_add (BBDB_BLIST_CHECK_INTERVAL, + g_timeout_add_seconds (BBDB_BLIST_CHECK_INTERVAL, (GSourceFunc) bbdb_timeout, NULL); } diff --git a/plugins/bbdb/bbdb.h b/plugins/bbdb/bbdb.h index e36a7737c3..55c88709b0 100644 --- a/plugins/bbdb/bbdb.h +++ b/plugins/bbdb/bbdb.h @@ -33,7 +33,7 @@ /* How often to poll the buddy list for changes (every two minutes) */ -#define BBDB_BLIST_CHECK_INTERVAL (2 * 60 * 1000) +#define BBDB_BLIST_CHECK_INTERVAL (2 * 60) /* bbdb.c */ EBook *bbdb_open_addressbook (int type); diff --git a/plugins/publish-calendar/publish-calendar.c b/plugins/publish-calendar/publish-calendar.c index 4adbe0d726..a901317dfb 100644 --- a/plugins/publish-calendar/publish-calendar.c +++ b/plugins/publish-calendar/publish-calendar.c @@ -352,11 +352,11 @@ add_timeout (EPublishUri *uri) /* Set the timeout for now+frequency */ switch (uri->publish_frequency) { case URI_PUBLISH_DAILY: - id = g_timeout_add (24 * 60 * 60 * 1000, (GSourceFunc) publish_no_succ_info, uri); + id = g_timeout_add_seconds (24 * 60 * 60, (GSourceFunc) publish, uri); g_hash_table_insert (uri_timeouts, uri, GUINT_TO_POINTER (id)); break; case URI_PUBLISH_WEEKLY: - id = g_timeout_add (7 * 24 * 60 * 60 * 1000, (GSourceFunc) publish_no_succ_info, uri); + id = g_timeout_add_seconds (7 * 24 * 60 * 60, (GSourceFunc) publish, uri); g_hash_table_insert (uri_timeouts, uri, GUINT_TO_POINTER (id)); break; } @@ -419,7 +419,7 @@ add_offset_timeout (EPublishUri *uri) publish (uri, FALSE); add_timeout (uri); } else { - id = g_timeout_add (((24 * 60 * 60) - elapsed) * 1000, (GSourceFunc) publish_no_succ_info, uri); + id = g_timeout_add_seconds (24 * 60 * 60 - elapsed, (GSourceFunc) publish, uri); g_hash_table_insert (uri_timeouts, uri, GUINT_TO_POINTER (id)); break; } @@ -429,7 +429,7 @@ add_offset_timeout (EPublishUri *uri) publish (uri, FALSE); add_timeout (uri); } else { - id = g_timeout_add (((7 * 24 * 60 * 60) - elapsed) * 1000, (GSourceFunc) publish_no_succ_info, uri); + id = g_timeout_add_seconds (7 * 24 * 60 * 60 - elapsed, (GSourceFunc) publish, uri); g_hash_table_insert (uri_timeouts, uri, GUINT_TO_POINTER (id)); break; } |