mirror of
https://github.com/textmate/textmate.git
synced 2026-01-20 20:27:59 -05:00
Change folder pop-up to pull-down
The menu contains two (non-selectable) “actions”. If we use a pop-up, we have to change the selection after the user select one of these actions, which isn’t the case with a pull-down menu.
This commit is contained in:
@@ -1136,9 +1136,6 @@ static NSMutableSet* SymmetricDifference (NSMutableSet* aSet, NSMutableSet* anot
|
||||
|
||||
- (IBAction)orderFrontGoToFolder:(id)sender
|
||||
{
|
||||
if(_headerView.folderPopUpButton.selectedItem.action == _cmd)
|
||||
[_headerView.folderPopUpButton selectItemAtIndex:0];
|
||||
|
||||
NSOpenPanel* panel = [NSOpenPanel openPanel];
|
||||
[panel setCanChooseFiles:NO];
|
||||
[panel setCanChooseDirectories:YES];
|
||||
|
||||
@@ -20,7 +20,7 @@ static NSButton* OakCreateImageButton (NSString* imageName)
|
||||
|
||||
static NSPopUpButton* OakCreatePopUpButton ()
|
||||
{
|
||||
NSPopUpButton* res = [NSPopUpButton new];
|
||||
NSPopUpButton* res = [[NSPopUpButton alloc] initWithFrame:NSZeroRect pullsDown:YES];
|
||||
[[res cell] setBackgroundStyle:NSBackgroundStyleLight];
|
||||
[res setContentCompressionResistancePriority:NSLayoutPriorityDefaultLow forOrientation:NSLayoutConstraintOrientationHorizontal];
|
||||
[res setBordered:NO];
|
||||
|
||||
Reference in New Issue
Block a user