| Index: runtime/bin/file_system_watcher_macos.cc
|
| diff --git a/runtime/bin/file_system_watcher_macos.cc b/runtime/bin/file_system_watcher_macos.cc
|
| index c06572f30e8e066507b2b3228e50341c8c1f24d7..b694bfddfd174478dc3ae1f024cd434c65d04e57 100644
|
| --- a/runtime/bin/file_system_watcher_macos.cc
|
| +++ b/runtime/bin/file_system_watcher_macos.cc
|
| @@ -18,6 +18,26 @@
|
| #include "bin/thread.h"
|
|
|
|
|
| +#ifndef MAC_OS_X_VERSION_10_7
|
| +enum {
|
| + kFSEventStreamCreateFlagFileEvents = 0x00000010
|
| +};
|
| +enum {
|
| + kFSEventStreamEventFlagItemCreated = 0x00000100,
|
| + kFSEventStreamEventFlagItemRemoved = 0x00000200,
|
| + kFSEventStreamEventFlagItemInodeMetaMod = 0x00000400,
|
| + kFSEventStreamEventFlagItemRenamed = 0x00000800,
|
| + kFSEventStreamEventFlagItemModified = 0x00001000,
|
| + kFSEventStreamEventFlagItemFinderInfoMod = 0x00002000,
|
| + kFSEventStreamEventFlagItemChangeOwner = 0x00004000,
|
| + kFSEventStreamEventFlagItemXattrMod = 0x00008000,
|
| + kFSEventStreamEventFlagItemIsFile = 0x00010000,
|
| + kFSEventStreamEventFlagItemIsDir = 0x00020000,
|
| + kFSEventStreamEventFlagItemIsSymlink = 0x00040000
|
| +};
|
| +#endif
|
| +
|
| +
|
| namespace dart {
|
| namespace bin {
|
|
|
| @@ -191,6 +211,12 @@ class FSEventsWatcher {
|
| };
|
|
|
|
|
| +#define kCFCoreFoundationVersionNumber10_7 635.00
|
| +bool FileSystemWatcher::IsSupported() {
|
| + return kCFCoreFoundationVersionNumber >= kCFCoreFoundationVersionNumber10_7;
|
| +}
|
| +
|
| +
|
| intptr_t FileSystemWatcher::WatchPath(const char* path,
|
| int events,
|
| bool recursive) {
|
|
|