aboutsummaryrefslogtreecommitdiffstats
path: root/src/bookmarks
diff options
context:
space:
mode:
authorDiego Escalante Urrelo <diegoe@svn.gnome.org>2007-01-03 16:08:12 +0800
committerDiego Escalante Urrelo <diegoe@src.gnome.org>2007-01-03 16:08:12 +0800
commitba82c09a4fad2c258eee6198c2c460fce28afd7b (patch)
treefbca03b2be9de64f2073ed154f184c798fac96c8 /src/bookmarks
parent6f06e1d567f30dc39347f8ce0f05ab16499aea7a (diff)
downloadgsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar.gz
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar.bz2
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar.lz
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar.xz
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.tar.zst
gsoc2013-epiphany-ba82c09a4fad2c258eee6198c2c460fce28afd7b.zip
Utilize GLib's new g_timeout_add_seconds to reduce context switches and
2007-01-03 Diego Escalante Urrelo <diegoe@svn.gnome.org> * embed/ephy-favicon-cache.c: (ephy_favicon_cache_init): * embed/ephy-history.c: (ephy_history_init): * lib/Makefile.am: * lib/ephy-glib-compat.h: * src/bookmarks/ephy-bookmarks.c: (ephy_bookmarks_save_delayed): * src/ephy-dbus.c: (session_filter_func), (system_filter_func): * src/ephy-extensions-manager.c: (reload_cb): * src/ephy-session.c: (confirm_shutdown_cb): Utilize GLib's new g_timeout_add_seconds to reduce context switches and improve CPU/power efficiency. Patch by Chris Wilson. svn path=/trunk/; revision=6783
Diffstat (limited to 'src/bookmarks')
-rw-r--r--src/bookmarks/ephy-bookmarks.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/bookmarks/ephy-bookmarks.c b/src/bookmarks/ephy-bookmarks.c
index 51c234627..6c36c08f1 100644
--- a/src/bookmarks/ephy-bookmarks.c
+++ b/src/bookmarks/ephy-bookmarks.c
@@ -38,6 +38,7 @@
#include "ephy-marshal.h"
#include "ephy-signal-accumulator.h"
#include "ephy-stock-icons.h"
+#include "ephy-glib-compat.h"
#include "eel-gconf-extensions.h"
@@ -50,7 +51,7 @@
#define EPHY_BOOKMARKS_XML_ROOT "ephy_bookmarks"
#define EPHY_BOOKMARKS_XML_VERSION "1.03"
-#define BOOKMARKS_SAVE_DELAY (3 * 1000) /* ms */
+#define BOOKMARKS_SAVE_DELAY 3 /* seconds */
#define MAX_FAVORITES_NUM 10
#define UPDATE_URI_DATA_KEY "updated-uri"
#define SD_RESOLVE_TIMEOUT 0 /* ms; 0 means no timeout */
@@ -289,7 +290,7 @@ ephy_bookmarks_save_delayed (EphyBookmarks *bookmarks, int delay)
if (delay > 0)
{
bookmarks->priv->save_timeout_id =
- g_timeout_add (BOOKMARKS_SAVE_DELAY,
+ g_timeout_add_seconds (BOOKMARKS_SAVE_DELAY,
(GSourceFunc) save_bookmarks_delayed,
bookmarks);
}