mirror of
https://github.com/MacPass/MacPass.git
synced 2025-12-14 09:22:33 +00:00
Fixed #657 exiting history display does not break entry display
This commit is contained in:
2
Cartfile
2
Cartfile
@@ -1,3 +1,3 @@
|
||||
github "sparkle-project/Sparkle" ~> 1.18.1
|
||||
github "mstarke/KeePassKit" "a0d459f52e0d4d3c0b0fba92de6dc54ddffba486"
|
||||
github "mstarke/KeePassKit" "6cf17cc6f730c72b02d69ef4becdaceabbc15bd7"
|
||||
github "mstarke/HNHUi" ~> 1.1
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
github "mstarke/HNHUi" "1.2"
|
||||
github "mstarke/KeePassKit" "a0d459f52e0d4d3c0b0fba92de6dc54ddffba486"
|
||||
github "mstarke/KeePassKit" "6cf17cc6f730c72b02d69ef4becdaceabbc15bd7"
|
||||
github "sparkle-project/Sparkle" "1.18.1"
|
||||
|
||||
@@ -112,8 +112,7 @@ NSString *const _MPTableSecurCellView = @"PasswordCell";
|
||||
_dataSource.viewController = self;
|
||||
_menuDelegate = [[MPEntryContextMenuDelegate alloc] init];
|
||||
_contextBarViewController = [[MPContextBarViewController alloc] init];
|
||||
NSString *entriesKeyPath = [NSString stringWithFormat:@"%@.%@", NSStringFromSelector(@selector(representedObject)), KPKEntriesArrayBinding];
|
||||
[_entryArrayController bind:NSContentArrayBinding toObject:self withKeyPath:entriesKeyPath options:@{NSNullPlaceholderBindingOption: @[]}];
|
||||
[self _setupEntryBindings];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
@@ -517,7 +516,7 @@ NSString *const _MPTableSecurCellView = @"PasswordCell";
|
||||
|
||||
- (void)_hideEntryHistory:(NSNotification *)notification {
|
||||
self.displayMode = MPDisplayModeEntries;
|
||||
[self.entryArrayController unbind:NSContentArrayBinding];
|
||||
[self _setupEntryBindings];
|
||||
self.entryArrayController.content = nil;
|
||||
[self _updateContextBar];
|
||||
MPDocument *document = notification.object;
|
||||
@@ -542,6 +541,11 @@ NSString *const _MPTableSecurCellView = @"PasswordCell";
|
||||
}
|
||||
}
|
||||
|
||||
- (void)_setupEntryBindings {
|
||||
NSString *entriesKeyPath = [NSString stringWithFormat:@"%@.%@", NSStringFromSelector(@selector(representedObject)), KPKEntriesArrayBinding];
|
||||
[self.entryArrayController bind:NSContentArrayBinding toObject:self withKeyPath:entriesKeyPath options:@{NSNullPlaceholderBindingOption: @[]}];
|
||||
}
|
||||
|
||||
- (void)_showContextBar {
|
||||
if(_isDisplayingContextBar) {
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user