gfx/tests/gfxTestCocoaHelper.mm
author Ben Turner <bent.mozilla@gmail.com>
Fri, 04 Feb 2011 11:48:59 -0800
changeset 61948 9414d1eaeeeb0342fc6e44e6c4efcdb10f213803
parent 47362 2e6221ac851892637fcb941b372d0daa4523b2e9
permissions -rw-r--r--
Bug 631452 - 'LazyIdleThread can race with newly dispatched events when shutting down'. r=sdwilsh, a=blocking.


#import <Cocoa/Cocoa.h>

#include "gfxTestCocoaHelper.h"

static NSAutoreleasePool *sPool = NULL;

void
CocoaPoolInit() {
  if (sPool)
    [sPool release];
  sPool = [[NSAutoreleasePool alloc] init];
}

void
CocoaPoolRelease() {
  [sPool release];
  sPool = NULL;
}