]> git.saurik.com Git - wxWidgets.git/commitdiff
better ownership handling
authorStefan Csomor <csomor@advancedconcepts.ch>
Thu, 9 Jun 2011 00:32:27 +0000 (00:32 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Thu, 9 Jun 2011 00:32:27 +0000 (00:32 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67900 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/osx/carbon/fontdlgosx.mm

index 7c2127132040ca48c7aef36177a43804c3b2c04d..2d42537db7fb0df016f46093dcd711e68cdecbf0 100644 (file)
@@ -167,6 +167,7 @@ int RunMixedFontDialog(wxFontDialog* dialog)
         NSRect rectBox = NSMakeRect( 0 , 0 , 192 , 40 );
         accessoryView = [[wxMacFontPanelAccView alloc] initWithFrame:rectBox];
         [fontPanel setAccessoryView:accessoryView];
+        [accessoryView release];
 
         [fontPanel setDefaultButtonCell:[[accessoryView okButton] cell]] ;
     }
@@ -220,7 +221,6 @@ int RunMixedFontDialog(wxFontDialog* dialog)
         retval = wxID_OK ;
     }
     [fontPanel setAccessoryView:nil];
-    [accessoryView release];
 
     return retval ;
 }