'코코아'에 해당되는 글 1건

  1. 2011.11.22 xcode 4.2에서 window based application 만드는 방법.

xcode 4.2에서 window based application 만드는 방법.

Dev/iOS 2011. 11. 22. 00:49


출처 http://upthere9.egloos.com/2816138

펌: http://nsec.tistory.com/112
iOS -> Application -> Empty Application

Project -> New File -> User Interface -> Empty -> Next -> Device Family ->iPhone -> Next -> MainWindow -> Create 
MainWindow.xib -> Placehoders -> File's Owner -> Identity Inspector - Custom Class -> Class -> UIApplication 입력

Object LIbrary에서 Object 를 Objects로 드래그
Objects -> Object -> Identity Inspector - Custom Class -> Class -> AppDelegate 입력

Object Library에서 Window를 Objects로 드래 그

AppDelegate.h를 열어 
"  @property (strongnonatomicUIWindow *window; " 를 

@property (strongnonatomicIBOutlet UIWindow *window; " 로 변경 후 저장.


MainWindow.xib -> Placehoders -> File's Owner ->  Connection Inspector -> Outlets -> delegate 를 Objects -> AppDelegate로 연결한다.
MainWindow.xib -> Placehoders -> Objects -> App Delegate -> Connection Inspector -> Outlets -> window를  Objects -> Window로 연결한다.


Project -> Summary -> iPhone/ iPod Deployment Info -> Main Interface -> MainWindow 입력

AppDelegate.m를 열어 아래부분을 주석 처리한다. 

    self.window = [[UIWindow allocinitWithFrame:[[UIScreen mainScreenbounds]];

    // Override point for customization after application launch.

    self.window.backgroundColor = [UIColor whiteColor]; 




'Dev > iOS' 카테고리의 다른 글

cocoa 초기 로딩 화면 관련.  (0) 2011.12.21
UIView 갱신  (0) 2011.12.20
UIButton 관련.  (0) 2011.11.21
ARC (Automatic Reference Counting)  (0) 2011.11.21
sqlite3 관련 라이브러리 추가시 경고 및 에러 발생시.  (0) 2011.11.11
: