[nautilus/gnome-2-32: 7/283] Set rate limit to the file monitor.
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/gnome-2-32: 7/283] Set rate limit to the file monitor.
- Date: Thu, 12 Aug 2010 11:04:37 +0000 (UTC)
commit dbc65e7b4807cd81b60a069bf032f0733f8ce572
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Mon Apr 12 03:34:23 2010 +0200
Set rate limit to the file monitor.
src/nautilus-bookmark-list.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/nautilus-bookmark-list.c b/src/nautilus-bookmark-list.c
index 67be610..25885d9 100644
--- a/src/nautilus-bookmark-list.c
+++ b/src/nautilus-bookmark-list.c
@@ -164,6 +164,8 @@ nautilus_bookmark_list_init (NautilusBookmarkList *bookmarks)
file = nautilus_bookmark_list_get_file ();
bookmarks->monitor = g_file_monitor_file (file, 0, NULL, NULL);
+ g_file_monitor_set_rate_limit (bookmarks->monitor, 1000);
+
g_signal_connect (bookmarks->monitor, "changed",
G_CALLBACK (bookmark_monitor_changed_cb), bookmarks);
@@ -604,8 +606,12 @@ error:
if (error)
g_error_free (error);
+ if (out)
+ g_object_unref (out);
+
/* re-enable bookmark file monitoring */
bookmarks->monitor = g_file_monitor_file (file, 0, NULL, NULL);
+ g_file_monitor_set_rate_limit (bookmarks->monitor, 1000);
g_signal_connect (bookmarks->monitor, "changed",
G_CALLBACK (bookmark_monitor_changed_cb), bookmarks);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]