]> git.sesse.net Git - vlc/commitdiff
Revert "macosx: NSScreen dealloc is not only called at end of execution of course."
authorDerk-Jan Hartman <hartman@videolan.org>
Mon, 22 Jun 2009 18:27:37 +0000 (20:27 +0200)
committerDerk-Jan Hartman <hartman@videolan.org>
Mon, 22 Jun 2009 19:03:41 +0000 (21:03 +0200)
This was even worse. +load() != init()
This reverts commit b5feb899d6047e2371ce18fe7d73c51fe270e2a1.

modules/gui/macosx/misc.m

index c9a4c4a07eadb9bb4aa9de30b295cca0e866f024..fe57179bc6570417461c169d94bfd4e74c4c5137 100644 (file)
@@ -129,14 +129,13 @@ static NSMutableArray *blackoutWindows = NULL;
 + (void)load
 {
     /* init our fake object attribute */
-    if( !blackoutWindows )
-        blackoutWindows = [NSMutableArray arrayWithCapacity:1];
+    blackoutWindows = [[NSMutableArray alloc] initWithCapacity:1];
 }
 
 - (void)dealloc
 {
-    [blackoutWindows makeObjectsPerformSelector:@selector(close)];
     [blackoutWindows removeAllObjects];
+    [blackoutWindows release];
     [super dealloc];
 }