diff options
Diffstat (limited to 'Source/SPUserManager.m')
-rw-r--r-- | Source/SPUserManager.m | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/Source/SPUserManager.m b/Source/SPUserManager.m index 9a9b916f..87b01cdc 100644 --- a/Source/SPUserManager.m +++ b/Source/SPUserManager.m @@ -112,7 +112,11 @@ static const NSString *SPTableViewNameColumnID = @"NameColumn"; // Set the button delegate [splitViewButtonBar setSplitViewDelegate:self]; - + + // Set schema table double-click actions + [grantedTableView setDoubleAction:@selector(doubleClickSchemaPriv:)]; + [availableTableView setDoubleAction:@selector(doubleClickSchemaPriv:)]; + [self _initializeUsers]; [self _initializeSchemaPrivs]; @@ -779,6 +783,23 @@ static const NSString *SPTableViewNameColumnID = @"NameColumn"; } /** + * Move double-clicked rows across to the other table, using the + * appropriate methods. + */ +- (IBAction)doubleClickSchemaPriv:(id)sender +{ + + // Ignore double-clicked header cells + if ([sender clickedRow] == -1) return; + + if (sender == availableTableView) { + [self addSchemaPriv:sender]; + } else { + [self removeSchemaPriv:sender]; + } +} + +/** * Refreshes the current list of users. */ - (IBAction)refresh:(id)sender |