diff --git a/MacPass/Base.lproj/GroupInspectorView.xib b/MacPass/Base.lproj/GroupInspectorView.xib index fcdd133c..418c6b90 100644 --- a/MacPass/Base.lproj/GroupInspectorView.xib +++ b/MacPass/Base.lproj/GroupInspectorView.xib @@ -76,18 +76,10 @@ - + - - - - - - - - - + diff --git a/MacPass/MPDocument+Search.m b/MacPass/MPDocument+Search.m index 1db04a95..15326746 100644 --- a/MacPass/MPDocument+Search.m +++ b/MacPass/MPDocument+Search.m @@ -116,7 +116,7 @@ NSString *const kMPDocumentSearchResultsKey = @"kMPDocumentSearchResul if(MPIsFlagSetInOptions(MPEntrySearchDoublePasswords, self.searchContext.searchFlags)) { __block NSMutableDictionary *passwordToEntryMap = [[NSMutableDictionary alloc] initWithCapacity:100]; /* Build up a usage map */ - [[self.root childEntries] enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) { + [[self.root searchableChildEntries] enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) { KPKEntry *entry = obj; /* skip entries without passwords */ if([entry.password length] > 0) { @@ -144,16 +144,16 @@ NSString *const kMPDocumentSearchResultsKey = @"kMPDocumentSearchResul KPKNode *node = evaluatedObject; return node.timeInfo.isExpired; }]; - return [[self.root childEntries] filteredArrayUsingPredicate:expiredPredicate]; + return [[self.root searchableChildEntries] filteredArrayUsingPredicate:expiredPredicate]; } /* Filter using predicates */ NSArray *predicates = [self _filterPredicatesWithString:self.searchContext.searchString]; if(predicates) { NSPredicate *fullFilter = [NSCompoundPredicate orPredicateWithSubpredicates:predicates]; - return [[self.root childEntries] filteredArrayUsingPredicate:fullFilter]; + return [[self.root searchableChildEntries] filteredArrayUsingPredicate:fullFilter]; } /* No filter, just return everything */ - return [self.root childEntries]; + return [self.root searchableChildEntries]; } - (NSArray *)_filterPredicatesWithString:(NSString *)string{ diff --git a/MacPass/MPGroupInspectorViewController.m b/MacPass/MPGroupInspectorViewController.m index 7e63361c..4550fdef 100644 --- a/MacPass/MPGroupInspectorViewController.m +++ b/MacPass/MPGroupInspectorViewController.m @@ -58,17 +58,29 @@ [[self view] layoutSubtreeIfNeeded]; NSMenu *autotypeMenu = self.autotypePopupButton.menu; - NSMenuItem *inheritItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_INHERIT", "") action:NULL keyEquivalent:@""]; - inheritItem.tag = KPKInherit; - NSMenuItem *yesItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_YES", "") action:NULL keyEquivalent:@""]; - yesItem.tag = KPKInheritYES; - NSMenuItem *noItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_NO", "") action:NULL keyEquivalent:@""]; - noItem.tag = KPKInheritNO; + NSMenuItem *inheritAutotype = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_INHERIT", "") action:NULL keyEquivalent:@""]; + inheritAutotype.tag = KPKInherit; + NSMenuItem *enableAutotype = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_YES", "") action:NULL keyEquivalent:@""]; + enableAutotype.tag = KPKInheritYES; + NSMenuItem *disableAutotype = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"AUTOTYPE_NO", "") action:NULL keyEquivalent:@""]; + disableAutotype.tag = KPKInheritNO; - [autotypeMenu addItem:inheritItem]; - [autotypeMenu addItem:yesItem]; - [autotypeMenu addItem:noItem]; + [autotypeMenu addItem:inheritAutotype]; + [autotypeMenu addItem:enableAutotype]; + [autotypeMenu addItem:disableAutotype]; + NSMenu *searchMenu = self.searchPopupButton.menu; + NSMenuItem *inheritSearch = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"SEARCH_INHERIT", "") action:NULL keyEquivalent:@""]; + inheritSearch.tag = KPKInherit; + NSMenuItem *includeInSearch = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"SEARCH_YES", "") action:NULL keyEquivalent:@""]; + includeInSearch.tag = KPKInheritYES; + NSMenuItem *excludeFromSearch = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"SEARCH_NO", "") action:NULL keyEquivalent:@""]; + excludeFromSearch.tag = KPKInheritNO; + + [searchMenu addItem:inheritSearch]; + [searchMenu addItem:includeInSearch]; + [searchMenu addItem:excludeFromSearch]; + /* void(^copyBlock)(NSTextField *textField) = ^void(NSTextField *textField) { [[MPPasteBoardController defaultController] copyObjects:@[ textField.stringValue ]]; diff --git a/MacPass/de.lproj/GroupInspectorView.strings b/MacPass/de.lproj/GroupInspectorView.strings index 2c6068f5..eb3898e5 100644 --- a/MacPass/de.lproj/GroupInspectorView.strings +++ b/MacPass/de.lproj/GroupInspectorView.strings @@ -8,15 +8,6 @@ /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "231"; */ "231.title" = "OtherViews"; -/* Class = "NSMenuItem"; title = "Inherit Search Settings"; ObjectID = "232"; */ -"232.title" = "Inherit Search Settings"; - -/* Class = "NSMenuItem"; title = "Include in Search"; ObjectID = "233"; */ -"233.title" = "Include in Search"; - -/* Class = "NSMenuItem"; title = "Exclude from Search"; ObjectID = "234"; */ -"234.title" = "Exclude from Search"; - /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "243"; */ "243.title" = "OtherViews"; diff --git a/MacPass/de.lproj/Localizable.strings b/MacPass/de.lproj/Localizable.strings index 7be89fbf..09ceb16f 100644 Binary files a/MacPass/de.lproj/Localizable.strings and b/MacPass/de.lproj/Localizable.strings differ diff --git a/MacPass/en.lproj/GroupInspectorView.strings b/MacPass/en.lproj/GroupInspectorView.strings index 2c6068f5..eb3898e5 100644 --- a/MacPass/en.lproj/GroupInspectorView.strings +++ b/MacPass/en.lproj/GroupInspectorView.strings @@ -8,15 +8,6 @@ /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "231"; */ "231.title" = "OtherViews"; -/* Class = "NSMenuItem"; title = "Inherit Search Settings"; ObjectID = "232"; */ -"232.title" = "Inherit Search Settings"; - -/* Class = "NSMenuItem"; title = "Include in Search"; ObjectID = "233"; */ -"233.title" = "Include in Search"; - -/* Class = "NSMenuItem"; title = "Exclude from Search"; ObjectID = "234"; */ -"234.title" = "Exclude from Search"; - /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "243"; */ "243.title" = "OtherViews"; diff --git a/MacPass/en.lproj/Localizable.strings b/MacPass/en.lproj/Localizable.strings index 3342611b..785e3f1e 100644 Binary files a/MacPass/en.lproj/Localizable.strings and b/MacPass/en.lproj/Localizable.strings differ diff --git a/MacPass/fr.lproj/GroupInspectorView.strings b/MacPass/fr.lproj/GroupInspectorView.strings index 2c6068f5..eb3898e5 100644 --- a/MacPass/fr.lproj/GroupInspectorView.strings +++ b/MacPass/fr.lproj/GroupInspectorView.strings @@ -8,15 +8,6 @@ /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "231"; */ "231.title" = "OtherViews"; -/* Class = "NSMenuItem"; title = "Inherit Search Settings"; ObjectID = "232"; */ -"232.title" = "Inherit Search Settings"; - -/* Class = "NSMenuItem"; title = "Include in Search"; ObjectID = "233"; */ -"233.title" = "Include in Search"; - -/* Class = "NSMenuItem"; title = "Exclude from Search"; ObjectID = "234"; */ -"234.title" = "Exclude from Search"; - /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "243"; */ "243.title" = "OtherViews"; diff --git a/MacPass/fr.lproj/Localizable.strings b/MacPass/fr.lproj/Localizable.strings index bbe4151d..29c9c8b7 100644 Binary files a/MacPass/fr.lproj/Localizable.strings and b/MacPass/fr.lproj/Localizable.strings differ diff --git a/MacPass/nl.lproj/GroupInspectorView.strings b/MacPass/nl.lproj/GroupInspectorView.strings index 7a8d21a8..90d58e81 100644 --- a/MacPass/nl.lproj/GroupInspectorView.strings +++ b/MacPass/nl.lproj/GroupInspectorView.strings @@ -8,15 +8,6 @@ /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "231"; */ "231.title" = "OverigeViews"; -/* Class = "NSMenuItem"; title = "Inherit Search Settings"; ObjectID = "232"; */ -"232.title" = "Erf Zoekinstellingen"; - -/* Class = "NSMenuItem"; title = "Include in Search"; ObjectID = "233"; */ -"233.title" = "Insluiten in Zoeken"; - -/* Class = "NSMenuItem"; title = "Exclude from Search"; ObjectID = "234"; */ -"234.title" = "Uitsluiten van Zoeken"; - /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "243"; */ "243.title" = "OverigeViews"; diff --git a/MacPass/nl.lproj/Localizable.strings b/MacPass/nl.lproj/Localizable.strings index 517e145d..dd669248 100644 Binary files a/MacPass/nl.lproj/Localizable.strings and b/MacPass/nl.lproj/Localizable.strings differ diff --git a/MacPass/zh-Hans.lproj/GroupInspectorView.strings b/MacPass/zh-Hans.lproj/GroupInspectorView.strings index 767ee822..05a26e3e 100644 --- a/MacPass/zh-Hans.lproj/GroupInspectorView.strings +++ b/MacPass/zh-Hans.lproj/GroupInspectorView.strings @@ -8,15 +8,6 @@ /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "231"; */ "231.title" = "OtherViews"; -/* Class = "NSMenuItem"; title = "Inherit Search Settings"; ObjectID = "232"; */ -"232.title" = "继承搜索设置"; - -/* Class = "NSMenuItem"; title = "Include in Search"; ObjectID = "233"; */ -"233.title" = "包含在搜索中"; - -/* Class = "NSMenuItem"; title = "Exclude from Search"; ObjectID = "234"; */ -"234.title" = "不包含在搜索中"; - /* Class = "NSMenu"; title = "OtherViews"; ObjectID = "243"; */ "243.title" = "OtherViews"; diff --git a/MacPass/zh-Hans.lproj/Localizable.strings b/MacPass/zh-Hans.lproj/Localizable.strings index db175392..38735431 100644 Binary files a/MacPass/zh-Hans.lproj/Localizable.strings and b/MacPass/zh-Hans.lproj/Localizable.strings differ