[tracker/miner-fs-refactor: 93/93] 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/93] libtracker-miner: Ensure the timer is set on ::directory-started
- Date: Fri, 7 Oct 2011 09:51:39 +0000 (UTC)
commit 194df2880af1581eb5bd014f96c038bafe3a8195
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 d972aa7..a2e011a 100644
--- a/src/libtracker-miner/tracker-miner-fs.c
+++ b/src/libtracker-miner/tracker-miner-fs.c
@@ -274,6 +274,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,
@@ -566,6 +569,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);
@@ -2572,6 +2578,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]