Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(111)

Side by Side Diff: experimental/iOSSampleApp/Shared/skia_ios.mm

Issue 373383003: ios fixes (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: only build gyp on ios Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | experimental/iOSShell/iOSShell-Info.plist » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #import <UIKit/UIKit.h> 1 #import <UIKit/UIKit.h>
2 #include "SkApplication.h" 2 #include "SkApplication.h"
3 3
4 extern void save_args(int argc, char *argv[]); 4 extern bool set_cmd_line_args(int argc, char *argv[], const char* dir);
5 5
6 int main(int argc, char *argv[]) { 6 int main(int argc, char *argv[]) {
7 signal(SIGPIPE, SIG_IGN); 7 signal(SIGPIPE, SIG_IGN);
8 NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; 8 NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
9 application_init(); 9 application_init();
10 save_args(argc, argv); 10 // Identify the documents directory
11 int retVal = UIApplicationMain(argc, argv, nil, nil); 11 NSArray *dirPaths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
12 NSString *docsDir = [dirPaths objectAtIndex:0];
13 const char *d = [docsDir UTF8String];
14
15 bool ranCommand = set_cmd_line_args(argc, argv, d);
16 int retVal = ranCommand ? 0 : UIApplicationMain(argc, argv, nil, nil);
12 application_term(); 17 application_term();
13 [pool release]; 18 [pool release];
14 return retVal; 19 return retVal;
15 } 20 }
OLDNEW
« no previous file with comments | « no previous file | experimental/iOSShell/iOSShell-Info.plist » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698