I am developing a Cocoa application with Finder Extension to set overlay icons on the file.
As soon as the user clicks on a folder that i am monitoring, i get a call to
the method
- beginObservingDirectoryAtURL
So my code is:
- (void)beginObservingDirectoryAtURL:(NSURL *)url {
// The user is now seeing the container's contents.
// If they see it in more than one view at a time, we're only told once.
NSLog(@"Current Path : %@", url.path);
NSArray<NSString*>* children = [[NSFileManager defaultManager] subPathsAtPath:url.Path];
}
The NSFileManager Default Manager path returns null when called from Finder Extension.
The same method call with the same path returns the elements in the main app.
Can I somehow enable monitoring a specific folder from Finder Extension?