aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/ICUTemplateMatcher.m2
-rw-r--r--Source/MGTemplateEngine.m4
-rw-r--r--Source/MGTemplateStandardMarkers.m2
-rw-r--r--Source/SPActivityTextFieldCell.m1
-rw-r--r--Source/SPCSVExporter.m3
-rw-r--r--Source/SPCSVParser.m8
-rw-r--r--Source/SPConnectionController.m4
-rw-r--r--Source/SPConnectionDelegate.h2
-rw-r--r--Source/SPCopyTable.m1
-rw-r--r--Source/SPDatabaseDocument.h1
-rw-r--r--Source/SPDatabaseViewController.h2
-rw-r--r--Source/SPExportController.m4
-rw-r--r--Source/SPExportFile.m1
-rw-r--r--Source/SPHistoryController.m1
-rw-r--r--Source/SPNavigatorController.m3
-rw-r--r--Source/SPPreferenceController.m1
-rw-r--r--Source/SPProcessListController.m5
-rw-r--r--Source/SPQueryController.m6
-rw-r--r--Source/SPTextView.m3
-rw-r--r--Source/SPWindowAdditions.m1
20 files changed, 36 insertions, 19 deletions
diff --git a/Source/ICUTemplateMatcher.m b/Source/ICUTemplateMatcher.m
index 8fcdb73c..84b8259a 100644
--- a/Source/ICUTemplateMatcher.m
+++ b/Source/ICUTemplateMatcher.m
@@ -20,7 +20,7 @@
- (id)initWithTemplateEngine:(MGTemplateEngine *)theEngine
{
- if (self = [super init]) {
+ if ((self = [super init])) {
self.engine = theEngine; // weak ref
}
diff --git a/Source/MGTemplateEngine.m b/Source/MGTemplateEngine.m
index 89ea3a1d..17acae65 100644
--- a/Source/MGTemplateEngine.m
+++ b/Source/MGTemplateEngine.m
@@ -60,7 +60,7 @@
- (id)init
{
- if (self = [super init]) {
+ if ((self = [super init])) {
_openBlocksStack = [[NSMutableArray alloc] init];
_globals = [[NSMutableDictionary alloc] init];
_markers = [[NSMutableDictionary alloc] init];
@@ -249,7 +249,7 @@
// Attempt to find firstVar in stack variables.
NSEnumerator *stack = [_openBlocksStack reverseObjectEnumerator];
NSDictionary *stackFrame = nil;
- while (stackFrame = [stack nextObject]) {
+ while ((stackFrame = [stack nextObject])) {
NSDictionary *vars = [stackFrame objectForKey:BLOCK_VARIABLES_KEY];
if (vars && [vars objectForKey:firstVar]) {
currObj = vars;
diff --git a/Source/MGTemplateStandardMarkers.m b/Source/MGTemplateStandardMarkers.m
index 0cbc8c66..184dab48 100644
--- a/Source/MGTemplateStandardMarkers.m
+++ b/Source/MGTemplateStandardMarkers.m
@@ -76,7 +76,7 @@
- (id)initWithTemplateEngine:(MGTemplateEngine *)theEngine
{
- if (self = [super init]) {
+ if ((self = [super init])) {
engine = theEngine;
forStack = [[NSMutableArray alloc] init];
sectionStack = [[NSMutableArray alloc] init];
diff --git a/Source/SPActivityTextFieldCell.m b/Source/SPActivityTextFieldCell.m
index f97101b4..6e4e142d 100644
--- a/Source/SPActivityTextFieldCell.m
+++ b/Source/SPActivityTextFieldCell.m
@@ -24,6 +24,7 @@
// More info at <http://code.google.com/p/sequel-pro/>
#import "SPActivityTextFieldCell.h"
+#import "SPTableInfo.h"
#define FAVORITE_NAME_FONT_SIZE 12.0
diff --git a/Source/SPCSVExporter.m b/Source/SPCSVExporter.m
index c874e9aa..e5d945c3 100644
--- a/Source/SPCSVExporter.m
+++ b/Source/SPCSVExporter.m
@@ -29,6 +29,7 @@
#import "SPFileHandle.h"
#import "SPTableData.h"
#import "SPExportUtilities.h"
+#import "SPExportFile.h"
@implementation SPCSVExporter
@@ -394,7 +395,7 @@
}
// Write data to disk
- [[[self exportOutputFile] exportFileHandle] synchronizeFile];
+ [[(SPExportFile*)[self exportOutputFile] exportFileHandle] synchronizeFile];
// Mark the process as not running
[self setExportProcessIsRunning:NO];
diff --git a/Source/SPCSVParser.m b/Source/SPCSVParser.m
index f1e63c72..f19c2d55 100644
--- a/Source/SPCSVParser.m
+++ b/Source/SPCSVParser.m
@@ -48,7 +48,7 @@
totalLengthParsed = 0;
// Loop through the results fetching process
- while (csvRowArray = [self getRowAsArrayAndTrimString:NO stringIsComplete:YES])
+ while ((csvRowArray = [self getRowAsArrayAndTrimString:NO stringIsComplete:YES]))
{
CFArrayAppendValue((CFMutableArrayRef)csvArray, csvRowArray);
}
@@ -603,7 +603,7 @@
#pragma mark -
- (id) init {
- if (self = [super init]) {
+ if ((self = [super init])) {
csvString = [[NSMutableString alloc] init];
[self _initialiseCSVParserDefaults];
}
@@ -611,14 +611,14 @@
}
- (id) initWithString:(NSString *)aString
{
- if (self = [super init]) {
+ if ((self = [super init])) {
csvString = [[NSMutableString alloc] initWithString:aString];
[self _initialiseCSVParserDefaults];
}
return self;
}
- (id) initWithContentsOfFile:(NSString *)path encoding:(NSStringEncoding)encoding error:(NSError **)error {
- if (self = [super init]) {
+ if ((self = [super init])) {
csvString = [[NSMutableString alloc] initWithContentsOfFile:path encoding:encoding error:error];
[self _initialiseCSVParserDefaults];
}
diff --git a/Source/SPConnectionController.m b/Source/SPConnectionController.m
index 41f44a1d..286960bc 100644
--- a/Source/SPConnectionController.m
+++ b/Source/SPConnectionController.m
@@ -34,6 +34,8 @@
#import "SPSSHTunnel.h"
#import "SPFavoriteNode.h"
#import "SPTableTextFieldCell.h"
+#import "SPGeneralPreferencePane.h"
+#import "SPDatabaseViewController.h"
@interface SPConnectionController (PrivateAPI)
@@ -85,7 +87,7 @@
*/
- (id) initWithDocument:(SPDatabaseDocument *)theTableDocument
{
- if (self = [super init]) {
+ if ((self = [super init])) {
tableDocument = theTableDocument;
databaseConnectionSuperview = [tableDocument databaseView];
databaseConnectionView = [tableDocument valueForKey:@"contentViewSplitter"];
diff --git a/Source/SPConnectionDelegate.h b/Source/SPConnectionDelegate.h
index deb28e68..c1d3bb5e 100644
--- a/Source/SPConnectionDelegate.h
+++ b/Source/SPConnectionDelegate.h
@@ -29,4 +29,6 @@
@interface SPDatabaseDocument (SPConnectionDelegate) <MCPConnectionDelegate>
+- (void) closeAndDisconnect;
+
@end
diff --git a/Source/SPCopyTable.m b/Source/SPCopyTable.m
index d87da60f..b69f23a1 100644
--- a/Source/SPCopyTable.m
+++ b/Source/SPCopyTable.m
@@ -23,6 +23,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#import <MCPKit/MCPKit.h>
+#import "MCPGeometryData.h"
#import "SPCopyTable.h"
#import "SPTableContent.h"
diff --git a/Source/SPDatabaseDocument.h b/Source/SPDatabaseDocument.h
index 8123bec3..b22eae94 100644
--- a/Source/SPDatabaseDocument.h
+++ b/Source/SPDatabaseDocument.h
@@ -305,6 +305,7 @@
- (IBAction)showUserManager:(id)sender;
- (IBAction)copyChecksumFromSheet:(id)sender;
- (void)setIsSavedInBundle:(BOOL)savedInBundle;
+- (void)setFileURL:(NSURL *)fileURL;
- (void)showConsole:(id)sender;
- (IBAction)showNavigator:(id)sender;
diff --git a/Source/SPDatabaseViewController.h b/Source/SPDatabaseViewController.h
index c19b7dcc..f7d795ca 100644
--- a/Source/SPDatabaseViewController.h
+++ b/Source/SPDatabaseViewController.h
@@ -49,4 +49,6 @@
// Table control
- (void)loadTable:(NSString *)aTable ofType:(NSInteger)aTableType;
+- (NSView *)databaseView;
+
@end
diff --git a/Source/SPExportController.m b/Source/SPExportController.m
index 9081b942..04138c75 100644
--- a/Source/SPExportController.m
+++ b/Source/SPExportController.m
@@ -33,6 +33,8 @@
#import "SPGrowlController.h"
#import "SPExportFile.h"
#import "SPAlertSheets.h"
+#import "SPExportFilenameUtilities.h"
+#import "SPDatabaseDocument.h"
// Constants
static const NSUInteger SPExportUIPadding = 20;
@@ -775,7 +777,6 @@ static const NSString *SPTableViewDropColumnID = @"drop";
NSUInteger padding = (2 * SPExportUIPadding);
CGFloat width = (!display) ? (windowFrame.size.width - (padding + 2)) : (windowFrame.size.width - ([exportOptionsTabBar frame].size.width + (padding + 4)));
- CGFloat width2 = (!display) ? (windowFrame.size.width - (padding + 2)) : (windowFrame.size.width - ([exportTableListButtonBar frame].size.width + (padding + 4)));
[NSAnimationContext beginGrouping];
[[NSAnimationContext currentContext] setDuration:0.3];
@@ -803,7 +804,6 @@ static const NSString *SPTableViewDropColumnID = @"drop";
BOOL isXML = (exportType == SPXMLExport);
BOOL isHTML = (exportType == SPHTMLExport);
BOOL isPDF = (exportType == SPPDFExport);
- BOOL isDot = (exportType == SPDotExport);
BOOL structureEnabled = [[uiStateDict objectForKey:@"SQLExportStructureEnabled"] integerValue];
BOOL contentEnabled = [[uiStateDict objectForKey:@"SQLExportContentEnabled"] integerValue];
diff --git a/Source/SPExportFile.m b/Source/SPExportFile.m
index 7e77d5de..4ccfa16c 100644
--- a/Source/SPExportFile.m
+++ b/Source/SPExportFile.m
@@ -24,6 +24,7 @@
// More info at <http://code.google.com/p/sequel-pro/>
#import "SPExportFile.h"
+#import "SPFileHandle.h"
@interface SPExportFile (PrivateAPI)
diff --git a/Source/SPHistoryController.m b/Source/SPHistoryController.m
index 107c24cb..9b810a00 100644
--- a/Source/SPHistoryController.m
+++ b/Source/SPHistoryController.m
@@ -26,6 +26,7 @@
#import "SPTableContent.h"
#import "SPTablesList.h"
#import "SPHistoryController.h"
+#import "SPDatabaseViewController.h"
@implementation SPHistoryController
diff --git a/Source/SPNavigatorController.m b/Source/SPNavigatorController.m
index a5d9f0b1..25eccbc8 100644
--- a/Source/SPNavigatorController.m
+++ b/Source/SPNavigatorController.m
@@ -31,8 +31,9 @@
#import "SPLogger.h"
#import "SPTooltip.h"
#import "SPAppController.h"
+#import "SPDatabaseViewController.h"
-#import <objc/runtime.h>
+#import <objc/message.h>
static SPNavigatorController *sharedNavigatorController = nil;
diff --git a/Source/SPPreferenceController.m b/Source/SPPreferenceController.m
index affcea80..3f7955c8 100644
--- a/Source/SPPreferenceController.m
+++ b/Source/SPPreferenceController.m
@@ -27,6 +27,7 @@
#import "SPPreferencesUpgrade.h"
#import "SPTablesPreferencePane.h"
#import "SPEditorPreferencePane.h"
+#import "SPGeneralPreferencePane.h"
@interface SPPreferenceController (PrivateAPI)
diff --git a/Source/SPProcessListController.m b/Source/SPProcessListController.m
index 82075eac..3d64e260 100644
--- a/Source/SPProcessListController.m
+++ b/Source/SPProcessListController.m
@@ -26,6 +26,7 @@
#import "SPProcessListController.h"
#import "SPDatabaseDocument.h"
#import "SPAlertSheets.h"
+#import "SPAppController.h"
static const NSString *SPTableViewIDColumnIdentifier = @"Id";
@@ -74,7 +75,7 @@ static const NSString *SPTableViewIDColumnIdentifier = @"Id";
*/
- (void)awakeFromNib
{
- [[self window] setTitle:[NSString stringWithFormat:@"%@ %@", [[[NSApp delegate] frontDocument] name], NSLocalizedString(@"Server Processes", @"server processes window title")]];
+ [[self window] setTitle:[NSString stringWithFormat:@"%@ %@", [[(SPAppController*)[NSApp delegate] frontDocument] name], NSLocalizedString(@"Server Processes", @"server processes window title")]];
[self setWindowFrameAutosaveName:@"ProcessList"];
@@ -644,7 +645,7 @@ static const NSString *SPTableViewIDColumnIdentifier = @"Id";
}
// If a match wasn't found then a custom value is set
- if (!found) [[items objectAtIndex:([items count] - 1)] setState:NSOnState];
+ if (!found) [(NSMenuItem*)[items objectAtIndex:([items count] - 1)] setState:NSOnState];
}
/**
diff --git a/Source/SPQueryController.m b/Source/SPQueryController.m
index 480d3e9e..ad9653ce 100644
--- a/Source/SPQueryController.m
+++ b/Source/SPQueryController.m
@@ -32,9 +32,9 @@
#define MESSAGE_TRUNCATE_CHARACTER_LENGTH 256
// Table view column identifier constants
-static const NSString *SPTableViewMessageColumnID = @"message";
-static const NSString *SPTableViewDateColumnID = @"messageDate";
-static const NSString *SPTableViewConnectionColumnID = @"messageConnection";
+static NSString *SPTableViewMessageColumnID = @"message";
+static NSString *SPTableViewDateColumnID = @"messageDate";
+static NSString *SPTableViewConnectionColumnID = @"messageConnection";
@interface SPQueryController (PrivateAPI)
diff --git a/Source/SPTextView.m b/Source/SPTextView.m
index 2fcebd14..769d4be8 100644
--- a/Source/SPTextView.m
+++ b/Source/SPTextView.m
@@ -33,6 +33,7 @@
#import "SPAlertSheets.h"
#import "RegexKitLite.h"
#import "SPBundleHTMLOutputController.h"
+#import "SPDatabaseViewController.h"
#pragma mark -
#pragma mark lex init
@@ -2673,7 +2674,7 @@ NSInteger alphabeticSort(id string1, id string2, void *reverse)
BOOL allowToCheckForUpperCase;
// now loop through all the tokens
- while (token=yylex()){
+ while ((token=yylex())){
allowToCheckForUpperCase = YES;
diff --git a/Source/SPWindowAdditions.m b/Source/SPWindowAdditions.m
index 9d99de4f..676019ee 100644
--- a/Source/SPWindowAdditions.m
+++ b/Source/SPWindowAdditions.m
@@ -25,6 +25,7 @@
#import "SPWindowAdditions.h"
#import "SPDatabaseDocument.h"
+#import "SPWindowController.h"
@implementation NSWindow (SPWindowAdditions)