aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPDatabaseDocument.m
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2011-03-07 20:12:52 +0000
committerstuconnolly <stuart02@gmail.com>2011-03-07 20:12:52 +0000
commit1e5288e9840e201a00bcb5ca3035d7aa807f1f8d (patch)
tree0c1a47953f57b71c41cc7a63e156629c6c9d645b /Source/SPDatabaseDocument.m
parent915a3831525bf3a9350648d82f86dd54ae366292 (diff)
downloadsequelpro-1e5288e9840e201a00bcb5ca3035d7aa807f1f8d.tar.gz
sequelpro-1e5288e9840e201a00bcb5ca3035d7aa807f1f8d.tar.bz2
sequelpro-1e5288e9840e201a00bcb5ca3035d7aa807f1f8d.zip
Bring outline view branch up to date with trunk (r3203:r3224).
Diffstat (limited to 'Source/SPDatabaseDocument.m')
-rw-r--r--Source/SPDatabaseDocument.m19
1 files changed, 12 insertions, 7 deletions
diff --git a/Source/SPDatabaseDocument.m b/Source/SPDatabaseDocument.m
index 4bc82a21..af639127 100644
--- a/Source/SPDatabaseDocument.m
+++ b/Source/SPDatabaseDocument.m
@@ -56,7 +56,10 @@
#import "SPDatabaseRename.h"
#import "SPServerSupport.h"
#import "SPTooltip.h"
-
+#import "SPDatabaseViewController.h"
+#import "SPBundleHTMLOutputController.h"
+#import "SPConnectionDelegate.h"
+#import "SPWindowController.h"
@interface SPDatabaseDocument (PrivateAPI)
@@ -2787,15 +2790,19 @@
[alert setAlertStyle:NSCriticalAlertStyle];
[alert runModal];
- return NO;
+
+ return;
}
NSError *error = nil;
+
[plist writeToFile:[NSString stringWithFormat:@"%@/info.plist", fileName] options:NSAtomicWrite error:&error];
+
if(error != nil){
NSAlert *errorAlert = [NSAlert alertWithError:error];
[errorAlert runModal];
- return NO;
+
+ return;
}
[[NSApp delegate] setSessionURL:fileName];
@@ -3306,7 +3313,6 @@
*/
- (void) updateWindowTitle:(id)sender
{
-
// Ensure a call on the main thread
if (![NSThread isMainThread]) return [[self onMainThread] updateWindowTitle:sender];
@@ -4721,7 +4727,7 @@
BOOL isDir;
if([fm fileExistsAtPath:queryFileName isDirectory:&isDir] && !isDir) {
NSError *inError = nil;
- NSString *query = [NSString stringWithContentsOfFile:queryFileName encoding:NSUTF8StringEncoding error:inError];
+ NSString *query = [NSString stringWithContentsOfFile:queryFileName encoding:NSUTF8StringEncoding error:&inError];
[fm removeItemAtPath:queryFileName error:nil];
if(inError == nil && query && [query length]) {
[tableContentInstance filterTable:query];
@@ -4741,7 +4747,6 @@
NSString *statusFileName = [NSString stringWithFormat:@"%@%@", SPURLSchemeQueryResultStatusPathHeader, docProcessID];
NSFileManager *fm = [NSFileManager defaultManager];
NSString *status = @"0";
- BOOL isDir;
BOOL userTerminated = NO;
BOOL doSyntaxHighlighting = NO;
BOOL doSyntaxHighlightingViaCSS = NO;
@@ -4890,7 +4895,7 @@
if([fm fileExistsAtPath:queryFileName isDirectory:&isDir] && !isDir) {
NSError *inError = nil;
- NSString *query = [NSString stringWithContentsOfFile:queryFileName encoding:NSUTF8StringEncoding error:inError];
+ NSString *query = [NSString stringWithContentsOfFile:queryFileName encoding:NSUTF8StringEncoding error:&inError];
[fm removeItemAtPath:queryFileName error:nil];
[fm removeItemAtPath:resultFileName error:nil];