From 644befb3e7d6c3fcce85da8a54d6b89de4ae2bbf Mon Sep 17 00:00:00 2001 From: Bibiko Date: Wed, 6 Jan 2010 17:47:47 +0000 Subject: =?UTF-8?q?=E2=80=A2=20fixed:=20do=20not=20disable=20User=20Accoun?= =?UTF-8?q?t=20if=20no=20table=20is=20selected=20=E2=80=A2=20fixed:=20if?= =?UTF-8?q?=20user=20cancelled=20"Add=20Database"=20reselect=20'Choose=20D?= =?UTF-8?q?atabase=20Button'=20instead=20of=20displaying=20"Add=20Database?= =?UTF-8?q?"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Source/TableDocument.m | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'Source') diff --git a/Source/TableDocument.m b/Source/TableDocument.m index 76707b2d..368c8a65 100644 --- a/Source/TableDocument.m +++ b/Source/TableDocument.m @@ -1131,8 +1131,15 @@ else if ([contextInfo isEqualToString:@"addDatabase"]) { if (returnCode == NSOKButton) { [self _addDatabase]; + } else { + // reset chooseDatabaseButton + if([[self database] length]) + [chooseDatabaseButton selectItemWithTitle:[self database]]; + else + [chooseDatabaseButton selectItemAtIndex:0]; } } + } /** @@ -3346,8 +3353,8 @@ if ([identifier isEqualToString:SPMainToolbarClearConsole]) { return ([[SPQueryController sharedQueryController] consoleMessageCount] > 0); } - - if (![identifier isEqualToString:SPMainToolbarCustomQuery]) { + + if (![identifier isEqualToString:SPMainToolbarCustomQuery] && ![identifier isEqualToString:SPMainToolbarUserManager]) { return (([tablesListInstance tableType] == SP_TABLETYPE_TABLE) || ([tablesListInstance tableType] == SP_TABLETYPE_VIEW)); } -- cgit v1.2.3