Commit a7440f78 authored by Petri Hintukainen's avatar Petri Hintukainen Committed by Jean-Baptiste Kempf

Qt: simplify call for the main menu

Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <jb@videolan.org>
parent 89682d39
......@@ -827,21 +827,7 @@ void InputManager::sectionMenu()
{
if( hasInput() )
{
vlc_value_t val, text;
if( var_Change( p_input, "title 0", VLC_VAR_GETCHOICES, &val, &text ) < 0 )
return;
/* XXX is it "Root" or "Title" we want here ?" (set 0 by default) */
int root = 0;
for( int i = 0; i < val.p_list->i_count; i++ )
{
if( !strcmp( text.p_list->p_values[i].psz_string, "Title" ) )
root = i;
}
var_FreeList( &val, &text );
var_SetInteger( p_input, "title 0", root );
var_TriggerCallback( p_input, "menu-title" );
}
}
......
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