Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3185)

Unified Diff: chrome/browser/media_galleries/fileapi/file_path_watcher_util.h

Issue 23499006: Media Galleries API Picasa: Add file watch to invalidate database data on disk write. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/media_galleries/fileapi/file_path_watcher_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/media_galleries/fileapi/file_path_watcher_util.h
diff --git a/chrome/browser/media_galleries/fileapi/file_path_watcher_util.h b/chrome/browser/media_galleries/fileapi/file_path_watcher_util.h
new file mode 100644
index 0000000000000000000000000000000000000000..f5a1e57045dfed1426159ba1991b4ed5728ec541
--- /dev/null
+++ b/chrome/browser/media_galleries/fileapi/file_path_watcher_util.h
@@ -0,0 +1,28 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_FILE_PATH_WATCHER_UTIL_H_
+#define CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_FILE_PATH_WATCHER_UTIL_H_
+
+#include "base/basictypes.h"
+#include "base/callback_forward.h"
+#include "base/files/file_path.h"
+#include "base/files/file_path_watcher.h"
+
+namespace chrome {
+
+typedef base::Callback<void(scoped_ptr<base::FilePathWatcher> watcher)>
+ FileWatchStartedCallback;
+
+// Called on the MediaTaskRunner to begin a file watch.
+// |watch_started_callback| is responsible for taking ownership of the
+// file watcher upon start. All callbacks are run on the MediaTaskRunner.
+void StartFilePathWatchOnMediaTaskRunner(
+ const base::FilePath& path,
+ const FileWatchStartedCallback& watch_started_callback,
+ const base::FilePathWatcher::Callback& path_changed_callback);
+
+} // namespace chrome
+
+#endif // CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_FILE_PATH_WATCHER_UTIL_H_
« no previous file with comments | « no previous file | chrome/browser/media_galleries/fileapi/file_path_watcher_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698