aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPConnectionDelegate.m
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2013-01-22 17:14:03 +0000
committerstuconnolly <stuart02@gmail.com>2013-01-22 17:14:03 +0000
commit9ab31cc5b60bf0e4519c989a3e9d213da50f888d (patch)
tree5e2967e092096dd830351a222cfe65d008d41fbd /Source/SPConnectionDelegate.m
parente2cc9e1953a142f182714fb02d7eca028398e368 (diff)
downloadsequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.tar.gz
sequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.tar.bz2
sequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.zip
Remove useless init and dealloc method comments and perform general tidy up.
Diffstat (limited to 'Source/SPConnectionDelegate.m')
-rw-r--r--Source/SPConnectionDelegate.m8
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/SPConnectionDelegate.m b/Source/SPConnectionDelegate.m
index 70ad76d0..473eef8c 100644
--- a/Source/SPConnectionDelegate.m
+++ b/Source/SPConnectionDelegate.m
@@ -181,19 +181,23 @@
/**
* Close the connection - should be performed on the main thread.
*/
-- (void) closeAndDisconnect
+- (void)closeAndDisconnect
{
#ifndef SP_REFACTOR
NSWindow *theParentWindow = [self parentWindow];
+
_isConnected = NO;
+
if ([[[self parentTabViewItem] tabView] numberOfTabViewItems] == 1) {
[theParentWindow orderOut:self];
[theParentWindow setAlphaValue:0.0f];
[theParentWindow performSelector:@selector(close) withObject:nil afterDelay:1.0];
- } else {
+ }
+ else {
[[[self parentTabViewItem] tabView] performSelector:@selector(removeTabViewItem:) withObject:[self parentTabViewItem] afterDelay:0.5];
[theParentWindow performSelector:@selector(makeKeyAndOrderFront:) withObject:nil afterDelay:0.6];
}
+
[self parentTabDidClose];
#endif
}