X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c4825ef73a5f190b8f39c59df098c3f39fa4464b..55410bb4f67febe1ca20654f078ea4fb9a6223ae:/src/osx/cocoa/gauge.mm diff --git a/src/osx/cocoa/gauge.mm b/src/osx/cocoa/gauge.mm index 71b9043b0a..895a70cae8 100644 --- a/src/osx/cocoa/gauge.mm +++ b/src/osx/cocoa/gauge.mm @@ -19,37 +19,20 @@ @interface wxNSProgressIndicator : NSProgressIndicator { - wxWidgetImpl* impl; } -- (void)setImplementation: (wxWidgetImpl *) theImplementation; -- (wxWidgetImpl*) implementation; -- (BOOL) isFlipped; - @end @implementation wxNSProgressIndicator -- (id)initWithFrame:(NSRect)frame -{ - [super initWithFrame:frame]; - impl = NULL; - return self; -} - -- (void)setImplementation: (wxWidgetImpl *) theImplementation -{ - impl = theImplementation; -} - -- (wxWidgetImpl*) implementation -{ - return impl; -} - -- (BOOL) isFlipped ++ (void)initialize { - return YES; + static BOOL initialized = NO; + if (!initialized) + { + initialized = YES; + wxOSXCocoaClassAddWXMethods( self ); + } } @end @@ -113,7 +96,6 @@ wxWidgetImplType* wxWidgetImpl::CreateGauge( wxWindowMac* wxpeer, [v setIndeterminate:FALSE]; [v setDoubleValue: (double) value]; wxWidgetCocoaImpl* c = new wxOSXGaugeCocoaImpl( wxpeer, v ); - [v setImplementation:c]; return c; }