[tracker/miner-fs-refactor: 93/110] libtracker-miner: Ensure the timer is set on ::directory-started
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/miner-fs-refactor: 93/110] libtracker-miner: Ensure the timer is set on ::directory-started
- Date: Wed, 2 Nov 2011 12:35:50 +0000 (UTC)
commit 0a8094076ad6e3d4aaf08151a061f847f0f8e16a
Author: Carlos Garnacho <carlos lanedo com>
Date: Fri Oct 7 11:41:32 2011 +0200
libtracker-miner: Ensure the timer is set on ::directory-started
src/libtracker-miner/tracker-miner-fs.c | 18 ++++++++++++++++++
1 files changed, 18 insertions(+), 0 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-miner-fs.c b/src/libtracker-miner/tracker-miner-fs.c
index 327728c..8096b6c 100644
--- a/src/libtracker-miner/tracker-miner-fs.c
+++ b/src/libtracker-miner/tracker-miner-fs.c
@@ -275,6 +275,9 @@ static void file_notifier_file_moved (TrackerFileNotifier
GFile *source,
GFile *dest,
gpointer user_data);
+static void file_notifier_directory_started (TrackerFileNotifier *notifier,
+ GFile *directory,
+ gpointer user_data);
static void file_notifier_directory_finished (TrackerFileNotifier *notifier,
GFile *directory,
guint directories_found,
@@ -567,6 +570,9 @@ tracker_miner_fs_init (TrackerMinerFS *object)
g_signal_connect (priv->file_notifier, "file-moved",
G_CALLBACK (file_notifier_file_moved),
object);
+ g_signal_connect (priv->file_notifier, "directory-started",
+ G_CALLBACK (file_notifier_directory_started),
+ object);
g_signal_connect (priv->file_notifier, "directory-finished",
G_CALLBACK (file_notifier_directory_finished),
object);
@@ -2573,6 +2579,18 @@ file_notifier_file_moved (TrackerFileNotifier *notifier,
}
static void
+file_notifier_directory_started (TrackerFileNotifier *notifier,
+ GFile *directory,
+ gpointer user_data)
+{
+ TrackerMinerFS *fs = user_data;
+
+ if (!fs->priv->timer) {
+ fs->priv->timer = g_timer_new ();
+ }
+}
+
+static void
file_notifier_directory_finished (TrackerFileNotifier *notifier,
GFile *directory,
guint directories_found,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]