mirror of
https://github.com/MacPass/MacPass.git
synced 2026-01-31 17:48:16 +00:00
Using NSSplitViewController for main split view.
This commit is contained in:
@@ -225,6 +225,7 @@ NSString *const _MPOutlinveViewHeaderViewIdentifier = @"HeaderCell";
|
||||
#pragma mark Notifications
|
||||
- (void)registerNotificationsForDocument:(MPDocument *)document {
|
||||
[NSNotificationCenter.defaultCenter addObserver:self selector:@selector(_didAddGroup:) name:MPDocumentDidAddGroupNotification object:document];
|
||||
[NSNotificationCenter.defaultCenter addObserver:self selector:@selector(_didRevertDocument:) name:MPDocumentDidRevertNotifiation object:document];
|
||||
}
|
||||
|
||||
- (void)clearSelection {
|
||||
@@ -268,6 +269,9 @@ NSString *const _MPOutlinveViewHeaderViewIdentifier = @"HeaderCell";
|
||||
[self.outlineView selectRowIndexes:[NSIndexSet indexSetWithIndex:groupRow] byExtendingSelection:NO];
|
||||
[self.outlineView scrollRowToVisible:groupRow];
|
||||
}
|
||||
- (void)_didRevertDocument:(NSNotification *)notification {
|
||||
[self clearSelection];
|
||||
}
|
||||
|
||||
- (id)itemUnderMouse {
|
||||
NSPoint mouseLocation = [self.outlineView.window mouseLocationOutsideOfEventStream];
|
||||
|
||||
Reference in New Issue
Block a user