aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBibiko <bibiko@eva.mpg.de>2011-01-17 14:12:56 +0000
committerBibiko <bibiko@eva.mpg.de>2011-01-17 14:12:56 +0000
commit6376447ae7597c9556ee2ba279c23308681be851 (patch)
treef9501e0dcc6169c8fe468ac5688f2f01afef3c4f
parent48e58b3dffdb08b8e5e1a2e699a62395420da7ce (diff)
downloadsequelpro-6376447ae7597c9556ee2ba279c23308681be851.tar.gz
sequelpro-6376447ae7597c9556ee2ba279c23308681be851.tar.bz2
sequelpro-6376447ae7597c9556ee2ba279c23308681be851.zip
• improved remove Bundle logic
• tried to fix setting the content of the treecontroller - maybe related to crash report 1931
-rw-r--r--Source/SPBundleEditorController.m5
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/SPBundleEditorController.m b/Source/SPBundleEditorController.m
index 3de09e36..f7347c76 100644
--- a/Source/SPBundleEditorController.m
+++ b/Source/SPBundleEditorController.m
@@ -131,6 +131,7 @@
[[commandBundleTree objectForKey:kChildrenKey] addObject:[NSMutableDictionary dictionaryWithObjectsAndKeys:[NSMutableArray array], kChildrenKey, SP_BUNDLEEDITOR_SCOPE_INPUTFIELD_STRING, kBundleNameKey, nil]];
[[commandBundleTree objectForKey:kChildrenKey] addObject:[NSMutableDictionary dictionaryWithObjectsAndKeys:[NSMutableArray array], kChildrenKey, SP_BUNDLEEDITOR_SCOPE_DATATABLE_STRING, kBundleNameKey, nil]];
[[commandBundleTree objectForKey:kChildrenKey] addObject:[NSMutableDictionary dictionaryWithObjectsAndKeys:[NSMutableArray array], kChildrenKey, SP_BUNDLEEDITOR_SCOPE_GENERAL_STRING, kBundleNameKey, nil]];
+ [commandBundleTreeController setContent:commandBundleTree];
// Init all needed menus
inputGeneralScopePopUpMenu = [[NSMenu alloc] initWithTitle:@""];
@@ -1036,6 +1037,9 @@
[self reloadBundles:self];
+ [commandBundleTreeController setSelectionIndexPath:[[selIndexPaths objectAtIndex:0] indexPathByRemovingLastIndex]];
+ [commandsOutlineView expandItem:[self _currentSelectedNode] expandChildren:NO];
+
// Set focus to table view to avoid an unstable state
[[self window] makeFirstResponder:commandsOutlineView];
@@ -1794,7 +1798,6 @@
[removeButton setEnabled:([[commandBundleTreeController selectedObjects] count] == 1 && ![[[commandBundleTreeController selectedObjects] objectAtIndex:0] objectForKey:kChildrenKey])];
[addButton setEnabled:([[commandBundleTreeController selectionIndexPath] length] > 1)];
- [commandBundleTreeController setContent:commandBundleTree];
NSUInteger *selPath[2];
selPath[0] = 0;
selPath[1] = 0;