Commit 2c1ec2e2 authored by David Fuhrmann's avatar David Fuhrmann

macosx: retain objects in MainMenu object

parent 898a0cea
...@@ -64,7 +64,7 @@ static VLCMainMenu *_o_sharedInstance = nil; ...@@ -64,7 +64,7 @@ static VLCMainMenu *_o_sharedInstance = nil;
} else { } else {
_o_sharedInstance = [super init]; _o_sharedInstance = [super init];
o_ptc_translation_dict = [NSDictionary dictionaryWithObjectsAndKeys: o_ptc_translation_dict = [[NSDictionary alloc] initWithObjectsAndKeys:
_NS("Track Number"), TRACKNUM_COLUMN, _NS("Track Number"), TRACKNUM_COLUMN,
_NS("Title"), TITLE_COLUMN, _NS("Title"), TITLE_COLUMN,
_NS("Author"), ARTIST_COLUMN, _NS("Author"), ARTIST_COLUMN,
...@@ -77,8 +77,9 @@ static VLCMainMenu *_o_sharedInstance = nil; ...@@ -77,8 +77,9 @@ static VLCMainMenu *_o_sharedInstance = nil;
_NS("URI"), URI_COLUMN, _NS("URI"), URI_COLUMN,
nil]; nil];
// this array also assigns tags (index) to type of menu item // this array also assigns tags (index) to type of menu item
o_ptc_menuorder = @[TRACKNUM_COLUMN, TITLE_COLUMN, ARTIST_COLUMN, DURATION_COLUMN, o_ptc_menuorder = [[NSArray alloc] initWithObjects: TRACKNUM_COLUMN, TITLE_COLUMN,
GENRE_COLUMN, ALBUM_COLUMN, DESCRIPTION_COLUMN, DATE_COLUMN, LANGUAGE_COLUMN, URI_COLUMN]; ARTIST_COLUMN, DURATION_COLUMN, GENRE_COLUMN, ALBUM_COLUMN,
DESCRIPTION_COLUMN, DATE_COLUMN, LANGUAGE_COLUMN, URI_COLUMN, nil];
} }
return _o_sharedInstance; return _o_sharedInstance;
...@@ -110,6 +111,9 @@ static VLCMainMenu *_o_sharedInstance = nil; ...@@ -110,6 +111,9 @@ static VLCMainMenu *_o_sharedInstance = nil;
[self releaseRepresentedObjects:[NSApp mainMenu]]; [self releaseRepresentedObjects:[NSApp mainMenu]];
[o_ptc_translation_dict release];
[o_ptc_menuorder release];
[super dealloc]; [super dealloc];
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment