]> git.saurik.com Git - wxWidgets.git/commitdiff
CodeWarrior (8.3 mwcc) can't figure out that it needs to do C++ automatic
authorDavid Elliott <dfe@tgwbd.org>
Sat, 30 Oct 2004 06:23:38 +0000 (06:23 +0000)
committerDavid Elliott <dfe@tgwbd.org>
Sat, 30 Oct 2004 06:23:38 +0000 (06:23 +0000)
conversion from wxObjcAutoRefFromAlloc<NSButton*> to NSButton* when it is
used as the receiver of a message.  Help it along with a static_cast.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30182 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/cocoa/button.mm

index 1774dd66ea959e8ca521c7eddb499106da75ea6e..5ae10895f687c9394808b24c8be45ff3c882dbe7 100644 (file)
@@ -96,10 +96,10 @@ static NSRect MakeNSButtonDefaultRect()
     // create at (10.0,10.0) with size 20.0x20.0 (just bogus values)
     wxObjcAutoRefFromAlloc<NSButton*> defaultButton = [[NSButton alloc]
             initWithFrame:NSMakeRect(10.0,10.0,20.0,20.0)];
-    [defaultButton setBezelStyle:NSRoundedBezelStyle];
-    [defaultButton setTitle:@""];
-    [defaultButton sizeToFit];
-    return [defaultButton frame];
+    [static_cast<NSButton*>(defaultButton) setBezelStyle:NSRoundedBezelStyle];
+    [static_cast<NSButton*>(defaultButton) setTitle:@""];
+    [static_cast<NSButton*>(defaultButton) sizeToFit];
+    return [static_cast<NSButton*>(defaultButton) frame];
 }
 
 wxSize wxButtonBase::GetDefaultSize()