diff options
author | stuconnolly <stuart02@gmail.com> | 2010-03-24 21:51:27 +0000 |
---|---|---|
committer | stuconnolly <stuart02@gmail.com> | 2010-03-24 21:51:27 +0000 |
commit | 3b70bf3ed475602fac435b86ab564423ae1dfdb0 (patch) | |
tree | 2328be21dbfdaec7e07caad38c2b46d26c76fcd7 /Source/SPNarrowDownCompletion.m | |
parent | 47f354070f1fa8dfeb46c4065075ee53de4c1626 (diff) | |
download | sequelpro-3b70bf3ed475602fac435b86ab564423ae1dfdb0.tar.gz sequelpro-3b70bf3ed475602fac435b86ab564423ae1dfdb0.tar.bz2 sequelpro-3b70bf3ed475602fac435b86ab564423ae1dfdb0.zip |
General tidy up, with a focus on consolidating more constants in SPConstants.h/m.
Diffstat (limited to 'Source/SPNarrowDownCompletion.m')
-rw-r--r-- | Source/SPNarrowDownCompletion.m | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/SPNarrowDownCompletion.m b/Source/SPNarrowDownCompletion.m index de9d39aa..40cbd2d9 100644 --- a/Source/SPNarrowDownCompletion.m +++ b/Source/SPNarrowDownCompletion.m @@ -27,6 +27,7 @@ // More info at <http://code.google.com/p/sequel-pro/> #import <Foundation/NSObjCRuntime.h> +#import <tgmath.h> #import "SPNarrowDownCompletion.h" #import "SPArrayAdditions.h" @@ -36,7 +37,7 @@ #import "SPQueryController.h" #import "RegexKitLite.h" #import "CMTextView.h" -#include <tgmath.h> +#import "SPConstants.h" @interface NSTableView (MovingSelectedRow) @@ -556,7 +557,7 @@ NSPoint old = NSMakePoint([self frame].origin.x, [self frame].origin.y + [self frame].size.height); - NSInteger displayedRows = [newFiltered count] < SP_NARROWDOWNLIST_MAX_ROWS ? [newFiltered count] : SP_NARROWDOWNLIST_MAX_ROWS; + NSInteger displayedRows = [newFiltered count] < SPNarrowDownCompletionMaxRows ? [newFiltered count] : SPNarrowDownCompletionMaxRows; CGFloat newHeight = ([theTableView rowHeight] + [theTableView intercellSpacing].height) * ((displayedRows) ? displayedRows : 1); if(caretPos.y >= 0 && (isAbove || caretPos.y < newHeight)) |