5 * Created by jan truetzschler on 4/12/06.
6 * Copyright (c) 2006 jan truetzschler. All rights reserved.
8 SuperCollider real time audio synthesis system
9 Copyright (c) 2002 James McCartney. All rights reserved.
10 http://www.audiosynth.com
12 This program is free software; you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 2 of the License, or
15 (at your option) any later version.
17 This program is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU General Public License for more details.
22 You should have received a copy of the GNU General Public License
23 along with this program; if not, write to the Free Software
24 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
28 #import "iPhoneSCNSWindow.h"
29 #import "iPhoneSCGraphView.h"
31 @interface SCNSWindowViewController : UIViewController
36 @implementation SCNSWindowViewController
38 - (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation
45 @implementation SCNSWindow
46 - (id) initWithFrame:(CGRect)bounds
48 if (self=[super initWithFrame:bounds])
51 viewController = [[SCNSWindowViewController alloc] init];
52 viewController.view = self;
53 viewController.tabBarItem.image = nil;
54 [self setBackgroundColor:[UIColor grayColor]];
55 self.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
60 - (BOOL) canBecomeKeyWindow { return YES; }
61 - (BOOL) hasBorders {return mHasBorders;}
62 - (void) setHasBorders: (BOOL) flag {mHasBorders = flag;}
63 - (void) setSCGraphView: (UIView*)view {mSCGraphView = view;}
64 - (UIView*) getSCGraphView {return mSCGraphView;}
65 - (void) setTitle:(NSString *)s
67 if (title) [title release];
68 title = [[NSString stringWithString:s] retain];
69 viewController.title = title;
71 - (NSString *) title {return title;}
72 - (UIViewController *) controller { return viewController; }
75 [(SCGraphView *) mSCGraphView willClose];
77 [viewController release];
83 if (title) [title release];
84 if (viewController) [viewController release];