From 71bfb735084722f1d3564b93ba35104e5379a2a9 Mon Sep 17 00:00:00 2001 From: David Elliott Date: Tue, 15 Jul 2003 15:27:59 +0000 Subject: [PATCH] Added wxAutoNSAutoreleasePool to DoGetBestSize method git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@21999 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/cocoa/control.mm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/cocoa/control.mm b/src/cocoa/control.mm index eac63d12e3..1f28f4532b 100644 --- a/src/cocoa/control.mm +++ b/src/cocoa/control.mm @@ -16,6 +16,8 @@ #include "wx/log.h" #endif +#include "wx/cocoa/autorelease.h" + #import IMPLEMENT_ABSTRACT_CLASS(wxControl, wxWindow) @@ -53,6 +55,7 @@ wxControl::~wxControl() wxSize wxControl::DoGetBestSize() const { + wxAutoNSAutoreleasePool pool; wxASSERT(m_cocoaNSView); NSRect storedRect = [m_cocoaNSView frame]; [GetNSControl() sizeToFit];