Created
December 29, 2009 17:02
-
-
Save jerodsanto/265428 to your computer and use it in GitHub Desktop.
CPPopUpButton as select box
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import <Foundation/CPObject.j> | |
@implementation AppController : CPObject | |
{ | |
} | |
- (void)applicationDidFinishLaunching:(CPNotification)aNotification | |
{ | |
var theWindow = [[CPWindow alloc] initWithContentRect:CGRectMakeZero() styleMask:CPBorderlessBridgeWindowMask], | |
contentView = [theWindow contentView]; | |
var dropdown = [[CPPopUpButton alloc] initWithFrame:CGRectMake(100,100,140,24)]; | |
[dropdown addItemsWithTitles:['Genre','Drama', 'Comedy', 'Action']]; | |
[contentView addSubview:dropdown]; | |
[theWindow orderFront:self]; | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment