diff options
author | stuconnolly <stuart02@gmail.com> | 2010-03-27 15:34:31 +0000 |
---|---|---|
committer | stuconnolly <stuart02@gmail.com> | 2010-03-27 15:34:31 +0000 |
commit | 0b4ee446f7052f964f704d8dfabe53103733325b (patch) | |
tree | f09193b597cf3f9771d77a4694d8dd0b5b0a98ed /Source/TableDocument.m | |
parent | 0559e08ff40bc2496c6af22beb4df99cf112e13b (diff) | |
download | sequelpro-0b4ee446f7052f964f704d8dfabe53103733325b.tar.gz sequelpro-0b4ee446f7052f964f704d8dfabe53103733325b.tar.bz2 sequelpro-0b4ee446f7052f964f704d8dfabe53103733325b.zip |
Add the ability to sort the connection favorites table view in the preferences. Sort options are by name, host or type as well as the option to be sorted in reverse order. This implements issue #490.
Diffstat (limited to 'Source/TableDocument.m')
-rw-r--r-- | Source/TableDocument.m | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/TableDocument.m b/Source/TableDocument.m index d73fa943..2a95c158 100644 --- a/Source/TableDocument.m +++ b/Source/TableDocument.m @@ -3148,6 +3148,12 @@ return ([[tablesListInstance valueForKeyPath:@"tables"] count] > 1); } + + // If validation for the sort favorites tableview items reaches here then the preferences window isn't + // open return NO. + if (([menuItem action] == @selector(sortFavorites:)) || ([menuItem action] == @selector(reverseFavoritesSortOrder:))) { + return NO; + } return [super validateMenuItem:menuItem]; } |