| Index: content/common/file_path_watcher/file_path_watcher.h
|
| diff --git a/content/common/file_path_watcher/file_path_watcher.h b/content/common/file_path_watcher/file_path_watcher.h
|
| index 2ec7af5ac5e1cb97825bb7f6f6a6c9213f0cf951..20ccfcc447b0854c69b6c2553574870ca27e214b 100644
|
| --- a/content/common/file_path_watcher/file_path_watcher.h
|
| +++ b/content/common/file_path_watcher/file_path_watcher.h
|
| @@ -16,8 +16,12 @@
|
| // This class lets you register interest in changes on a FilePath.
|
| // The delegate will get called whenever the file or directory referenced by the
|
| // FilePath is changed, including created or deleted. Due to limitations in the
|
| -// underlying OS APIs, spurious notifications might occur that don't relate to
|
| -// an actual change to the watch target.
|
| +// underlying OS APIs, FilePathWatcher has slightly different semantics on OS X
|
| +// than on Windows or Linux. FilePathWatcher on Linux and Windows will detect
|
| +// modifications to files in a watched directory. FilePathWatcher on Mac will
|
| +// detect the creation and deletion of files in a watched directory, but will
|
| +// not detect modifications to those files. See file_path_watcher_mac.cc for
|
| +// details.
|
| class FilePathWatcher {
|
| public:
|
| // Declares the callback client code implements to receive notifications. Note
|
| @@ -36,15 +40,10 @@ class FilePathWatcher {
|
| ~FilePathWatcher();
|
|
|
| // Register interest in any changes on |path|. OnPathChanged will be called
|
| - // back for each change. Returns true on success. |loop| is only used
|
| - // by the Mac implementation right now, and must be backed by a CFRunLoop
|
| - // based MessagePump. This is usually going to be a MessageLoop of type
|
| - // TYPE_UI.
|
| + // back for each change. Returns true on success.
|
| // OnFilePathChanged() will be called on the same thread as Watch() is called,
|
| // which should have a MessageLoop of TYPE_IO.
|
| - bool Watch(const FilePath& path,
|
| - Delegate* delegate,
|
| - base::MessageLoopProxy* loop) WARN_UNUSED_RESULT;
|
| + bool Watch(const FilePath& path, Delegate* delegate) WARN_UNUSED_RESULT;
|
|
|
| class PlatformDelegate;
|
|
|
| @@ -73,13 +72,8 @@ class FilePathWatcher {
|
| PlatformDelegate();
|
|
|
| // Start watching for the given |path| and notify |delegate| about changes.
|
| - // |loop| is only used by the Mac implementation right now, and must be
|
| - // backed by a CFRunLoop based MessagePump. This is usually going to be a
|
| - // MessageLoop of type TYPE_UI.
|
| - virtual bool Watch(
|
| - const FilePath& path,
|
| - Delegate* delegate,
|
| - base::MessageLoopProxy* loop) WARN_UNUSED_RESULT = 0;
|
| + virtual bool Watch(const FilePath& path,
|
| + Delegate* delegate) WARN_UNUSED_RESULT = 0;
|
|
|
| // Stop watching. This is called from FilePathWatcher's dtor in order to
|
| // allow to shut down properly while the object is still alive.
|
|
|