Fix cmdline argument passing in SampleApp/Mac.
When SampleApp was ported to Cocoa, it lost the ability to pass a test
name on the command line. Fix it.
Review URL: http://codereview.appspot.com/5328042/
git-svn-id: http://skia.googlecode.com/svn/trunk@2538 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/utils/mac/SkSampleNSView.mm b/src/utils/mac/SkSampleNSView.mm
index 0d3abd6..242544f 100644
--- a/src/utils/mac/SkSampleNSView.mm
+++ b/src/utils/mac/SkSampleNSView.mm
@@ -8,11 +8,12 @@
#import "SkSampleNSView.h"
#include "SampleApp.h"
+#include <crt_externs.h>
@implementation SkSampleNSView
- (id)initWithDefaults {
if (self = [super initWithDefaults]) {
- fWind = new SampleWindow(self, NULL, NULL, NULL);
+ fWind = new SampleWindow(self, *_NSGetArgc(), *_NSGetArgv(), NULL);
}
return self;
}