Commit 58049342 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt4 - Preferences: Add an option and the code needed to start with the...

Qt4 - Preferences: Add an option and the code needed to start with the advanced preferences. 1337 function.

parent cd0a847e
......@@ -100,7 +100,14 @@ PrefsDialog::PrefsDialog( intf_thread_t *_p_intf ) : QVLCFrame( _p_intf )
tree_panel_l->setMargin( 1 );
main_panel_l->setMargin( 3 );
if( config_GetInt( p_intf, "qt-advanced-pref") == 1 )
{
setAll();
}
else
{
setSmall();
}
BUTTONACT( save, save() );
BUTTONACT( cancel, cancel() );
......@@ -137,6 +144,7 @@ void PrefsDialog::setAll()
if( !advanced_panel )
advanced_panel = new PrefsPanel( main_panel );
main_panel_l->addWidget( advanced_panel );
all->setChecked( true );
advanced_panel->show();
}
......@@ -165,6 +173,7 @@ void PrefsDialog::setSmall()
if( !simple_panel )
simple_panel = new SPrefsPanel( p_intf, main_panel, SPrefsDefaultCat );
main_panel_l->addWidget( simple_panel );
small->setChecked( true );
simple_panel->show();
}
......
......@@ -43,6 +43,11 @@ static void ShowDialog ( intf_thread_t *, int, int, intf_dialog_args_t * );
/*****************************************************************************
* Module descriptor
*****************************************************************************/
#define ADVANCED_PREFS_TEXT N_("Show advanced prefs over simple")
#define ADVANCED_PREFS_LONGTEXT N_("Show advanced preferences and not simple" \
"preferences when opening the preferences " \
"dialog.")
vlc_module_begin();
set_shortname( (char *)"Qt" );
set_description( (char*)_("Qt interface") );
......@@ -57,7 +62,10 @@ vlc_module_begin();
add_submodule();
set_description( "Dialogs provider" );
set_capability( "dialogs provider", 51 );
add_bool( "qt-always-video", VLC_FALSE, NULL, "FIXME", "FIXME", VLC_TRUE );
add_bool( "qt-always-video", VLC_FALSE, NULL, "FIXME", "FIXME",
VLC_TRUE );
add_bool( "qt-advanced-pref", VLC_FALSE, NULL, ADVANCED_PREFS_TEXT,
ADVANCED_PREFS_LONGTEXT, VLC_FALSE );
set_callbacks( OpenDialogs, Close );
vlc_module_end();
......
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