yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 1 | |
| 2 | /* |
| 3 | * Copyright 2011 Google Inc. |
| 4 | * |
| 5 | * Use of this source code is governed by a BSD-style license that can be |
| 6 | * found in the LICENSE file. |
| 7 | */ |
bsalomon@google.com | f75b84e | 2011-09-29 14:58:28 +0000 | [diff] [blame] | 8 | |
yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 9 | #import <Cocoa/Cocoa.h> |
| 10 | #include "SkApplication.h" |
caryclark@google.com | 78c6ed0 | 2012-01-27 16:52:38 +0000 | [diff] [blame] | 11 | |
yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 12 | int main(int argc, char *argv[]) { |
| 13 | signal(SIGPIPE, SIG_IGN); |
mtklein | d157b6a | 2014-10-21 07:21:36 -0700 | [diff] [blame^] | 14 | /*NSAutoreleasePool* pool = */ [[NSAutoreleasePool alloc] init]; |
yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 15 | application_init(); |
| 16 | int retVal = NSApplicationMain(argc, (const char **)argv); |
reed | 3fc02f1 | 2014-10-07 03:59:34 -0700 | [diff] [blame] | 17 | |
| 18 | #if 0 |
| 19 | // we don't expect NSApplicationMain to return. See our applicationShouldTerminate handler. |
yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 20 | application_term(); |
| 21 | [pool release]; |
reed | 3fc02f1 | 2014-10-07 03:59:34 -0700 | [diff] [blame] | 22 | #endif |
yangsu@google.com | a854041 | 2011-08-30 14:40:49 +0000 | [diff] [blame] | 23 | return retVal; |
caryclark@google.com | 78c6ed0 | 2012-01-27 16:52:38 +0000 | [diff] [blame] | 24 | } |