All pastes #809077 Raw Edit

Untitled

public text v1 · immutable
·published 2007-12-08 06:13 UTC
rendered paste body
#import "iDeeJay.h"

@implementation iDeeJay

- (void) showDecks
{
	UIImage *vinylDecks[2];

	vinylDecks[0] = [UIImage imageNamed:@"vinyl_001.jpg"];
	vinylDecks[1] = [UIImage imageNamed:@"vinyl_001.jpg"];


}

- (void) applicationDidFinishLaunching: (id) unused
{
	float black[4]	=	{0.0f, 0.0f, 0.0f, 1.0f};
	[UIHardware _setStatusBarHeight:0.0f];
	[self setStatusBarMode:2 orientation:0 duration:0.0f fenceID:0];

	struct CGRect rect	= [UIHardware fullScreenApplicationContentRect];

	rect.origin.x		= rect.origin.y = 0;

	/* Initialize the main window */
	UIWindow* window	= [[UIWindow alloc] initWithContentRect: rect];
	[window orderFront: self];
	[window makeKey: self];
	[window _setHidden: false];
	/*UIImageView *bg = [[UIImageView alloc] initWithImage: [UIImage applicationImageNamed:@"bg.jpg"]] autorelease];*/

	UINavigationBar *nav = [[UINavigationBar alloc] initWithFrame: CGRectMake(320.0f, 0.0f, 320.0f, 0.0f)];
	[nav showButtonsWithLeftTitle: @"Exit" rightTitle: @"Playlists" leftBack: YES];
	[nav setPrompt:@"iDeeJay v0.1"];
	[nav setBarStyle: 2];
	
	/* Initialize the main view */
	UIView* mainView	= [[[UIView alloc] initWithFrame: rect] autorelease];
	[mainView setBackgroundColor: CGColorCreate(CGColorSpaceCreateDeviceRGB(), black)];
	[window setContentView: mainView];
	[mainView setRotationDegrees:90 duration:0];
	[mainView addSubview: nav];
	/*[mainView addSubview: bg];*/
	
	[self showDecks];
}

@end