]> git.saurik.com Git - wxWidgets.git/blame - include/wx/cocoa/autorelease.h
wxMessageBox off the main thread lost result code.
[wxWidgets.git] / include / wx / cocoa / autorelease.h
CommitLineData
140e7468
DE
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/cocoa/autorelease.h
3// Purpose: Automatic NSAutoreleasePool functionality
4// Author: David Elliott
03647350 5// Modified by:
140e7468 6// Created: 2003/07/11
140e7468 7// Copyright: (c) 2003 David Elliott <dfe@cox.net>
65571936 8// Licence: wxWindows licence
140e7468
DE
9/////////////////////////////////////////////////////////////////////////////
10
11#ifndef __WX_COCOA_AUTORELEASE_H__
12#define __WX_COCOA_AUTORELEASE_H__
13
14#import <Foundation/NSAutoreleasePool.h>
15
16class wxAutoNSAutoreleasePool
17{
18public:
19 wxAutoNSAutoreleasePool()
20 {
21 m_pool = [[NSAutoreleasePool alloc] init];
22 }
23 ~wxAutoNSAutoreleasePool()
24 {
25 [m_pool release];
26 }
27protected:
28 NSAutoreleasePool *m_pool;
29};
30
31#endif //__WX_COCOA_AUTORELEASE_H__