mirror of
https://github.com/textmate/textmate.git
synced 2026-04-28 03:00:34 -04:00
Allow editing .tm_properties files from bundle item chooser
This commit is contained in:
@@ -486,6 +486,8 @@ BOOL HasDocumentWindow (NSArray* windows)
|
||||
|
||||
if(NSString* uuid = [[[sender selectedItems] lastObject] objectForKey:@"uuid"])
|
||||
[[BundleEditor sharedInstance] revealBundleItem:bundles::lookup(to_s(uuid))];
|
||||
else if(NSString* path = [[[sender selectedItems] lastObject] objectForKey:@"path"])
|
||||
OakOpenDocuments(@[ path ]);
|
||||
}
|
||||
|
||||
- (void)editBundleItemWithUUIDString:(NSString*)uuidString
|
||||
|
||||
@@ -746,7 +746,7 @@ static std::vector<bundles::item_ptr> relevant_items_in_scope (scope::context_t
|
||||
- (BOOL)canEdit
|
||||
{
|
||||
BundleItemChooserItem* item = self.tableView.selectedRow != -1 ? self.items[self.tableView.selectedRow] : nil;
|
||||
return item.uuid && self.editAction;
|
||||
return item.uuid && self.editAction || item.path;
|
||||
}
|
||||
|
||||
- (void)accept:(id)sender
|
||||
|
||||
Reference in New Issue
Block a user