aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authormltownsend <mltownsend@gmail.com>2009-12-02 20:02:01 +0000
committermltownsend <mltownsend@gmail.com>2009-12-02 20:02:01 +0000
commit7c6172a54aae1c71bc4432afa5799293624c9d7f (patch)
tree81b278564dbc53c1d29dbbb5c24d6ba3cc91f014 /Source
parentaf16f1e3bb44a4a782dbe1bee18513ce7d4738c6 (diff)
downloadsequelpro-7c6172a54aae1c71bc4432afa5799293624c9d7f.tar.gz
sequelpro-7c6172a54aae1c71bc4432afa5799293624c9d7f.tar.bz2
sequelpro-7c6172a54aae1c71bc4432afa5799293624c9d7f.zip
Fixed user sort and added Anonymous displayName when username is empty
Diffstat (limited to 'Source')
-rw-r--r--Source/SPUserManager.h1
-rw-r--r--Source/SPUserManager.m7
2 files changed, 8 insertions, 0 deletions
diff --git a/Source/SPUserManager.h b/Source/SPUserManager.h
index 48c8ad3f..0e619563 100644
--- a/Source/SPUserManager.h
+++ b/Source/SPUserManager.h
@@ -69,4 +69,5 @@
- (BOOL)updateUsers:(NSArray *)updatedUsers;
- (BOOL)grantPrivilegesToUser:(NSManagedObject *)user;
+- (NSArray *)treeSortDescriptors;
@end
diff --git a/Source/SPUserManager.m b/Source/SPUserManager.m
index 40ec31e4..0a362395 100644
--- a/Source/SPUserManager.m
+++ b/Source/SPUserManager.m
@@ -226,6 +226,7 @@
}
// Reload data of the outline view with the changes.
[outlineView reloadData];
+ [treeController rearrangeObjects];
}
/**
@@ -375,6 +376,12 @@
}
}
+- (NSArray *)treeSortDescriptors
+{
+ NSSortDescriptor *descriptor = [[NSSortDescriptor alloc] initWithKey:@"displayName" ascending:YES];
+ return [NSArray arrayWithObject:descriptor];
+}
+
#pragma mark -
#pragma mark General IBAction methods