Commit f91af6c0 authored by David Fuhrmann's avatar David Fuhrmann

macosx: correctly toggle enabled state of record menu item

parent a1b3cbc4
......@@ -576,8 +576,6 @@ static VLCMainMenu *_o_sharedInstance = nil;
playlist_t * p_playlist = pl_Get(p_intf);
input_thread_t * p_input = playlist_CurrentInput(p_playlist);
if (p_input != NULL) {
[o_mi_record setEnabled: var_GetBool(p_input, "can-record")];
[self setupVarMenuItem: o_mi_program target: (vlc_object_t *)p_input
var: "program" selector: @selector(toggleVar:)];
......@@ -628,7 +626,6 @@ static VLCMainMenu *_o_sharedInstance = nil;
[o_mi_ffmpeg_pp setEnabled:YES];
vlc_object_release(p_input);
} else {
[o_mi_record setEnabled: NO];
[o_mi_ffmpeg_pp setEnabled:NO];
}
}
......@@ -1534,6 +1531,10 @@ static VLCMainMenu *_o_sharedInstance = nil;
if (!p_input)
bEnabled = FALSE;
[self setupMenus]; /* Make sure input menu is up to date */
} else if ([o_title isEqualToString: _NS("Record")]) {
bEnabled = FALSE;
if (p_input)
bEnabled = var_GetBool(p_input, "can-record");
} else if ([o_title isEqualToString: _NS("Previous")] ||
[o_title isEqualToString: _NS("Next")]) {
PL_LOCK;
......
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