Spotlight: Search scopes work and crash solved. We now return to regular programming.
parent
b6a46c5ca1
commit
94f23c4fdb
|
@ -79,6 +79,20 @@ static NSPredicate * musicOnlyPredicate = nil;
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (void)awakeFromNib
|
||||||
|
{
|
||||||
|
// We want to bind the query's search scope to the user default that is
|
||||||
|
// set from the NSPathControl.
|
||||||
|
NSDictionary *bindOptions =
|
||||||
|
[NSDictionary dictionaryWithObject:@"StringToSearchScopeTransformer"
|
||||||
|
forKey:NSValueTransformerNameBindingOption];
|
||||||
|
|
||||||
|
[self.query bind:@"searchScopes"
|
||||||
|
toObject:[NSUserDefaultsController sharedUserDefaultsController]
|
||||||
|
withKeyPath:@"values.spotlightSearchPath"
|
||||||
|
options:bindOptions];
|
||||||
|
}
|
||||||
|
|
||||||
- (void)performSearch
|
- (void)performSearch
|
||||||
{
|
{
|
||||||
NSPredicate *searchPredicate;
|
NSPredicate *searchPredicate;
|
||||||
|
|
Loading…
Reference in New Issue