aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2013-08-26 23:01:38 +0000
committerrowanbeentje <rowan@beent.je>2013-08-26 23:01:38 +0000
commit64eb9b76d33d6cd28a3ad7caee8e792e4a2cffd3 (patch)
treea8af43b561a47a0a051847cabde05599cca66536 /Source
parentd99de6f4c04fa0da1575963d161182c92cf3721f (diff)
downloadsequelpro-64eb9b76d33d6cd28a3ad7caee8e792e4a2cffd3.tar.gz
sequelpro-64eb9b76d33d6cd28a3ad7caee8e792e4a2cffd3.tar.bz2
sequelpro-64eb9b76d33d6cd28a3ad7caee8e792e4a2cffd3.zip
- Fix exceptions when shift-tabbing back from a very early cell in the Structure view to the last cell (http://spbug.com/l/2122)
Diffstat (limited to 'Source')
-rw-r--r--Source/SPTableStructureDelegate.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/SPTableStructureDelegate.m b/Source/SPTableStructureDelegate.m
index c8d03aff..f2003618 100644
--- a/Source/SPTableStructureDelegate.m
+++ b/Source/SPTableStructureDelegate.m
@@ -501,11 +501,11 @@
if ( row > 0) {
[tableSourceView selectRowIndexes:[NSIndexSet indexSetWithIndex:row-1] byExtendingSelection:NO];
- [tableSourceView editColumn:([tableFields count]-1) row:row-1 withEvent:nil select:YES];
+ [tableSourceView editColumn:([tableSourceView numberOfColumns]-1) row:row-1 withEvent:nil select:YES];
}
else {
[tableSourceView selectRowIndexes:[NSIndexSet indexSetWithIndex:([tableFields count]-1)] byExtendingSelection:NO];
- [tableSourceView editColumn:([tableFields count]-1) row:([tableSourceView numberOfRows]-1) withEvent:nil select:YES];
+ [tableSourceView editColumn:([tableSourceView numberOfColumns]-1) row:([tableSourceView numberOfRows]-1) withEvent:nil select:YES];
}
}