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

Qt: use the new function to factorize code

Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent effc65cc
...@@ -725,20 +725,10 @@ ModuleListConfigControl::~ModuleListConfigControl() ...@@ -725,20 +725,10 @@ ModuleListConfigControl::~ModuleListConfigControl()
void ModuleListConfigControl::checkbox_lists( module_t *p_parser ) void ModuleListConfigControl::checkbox_lists( module_t *p_parser )
{ {
QCheckBox *cb = new QCheckBox( qtr( module_GetLongName( p_parser ) ) );
checkBoxListItem *cbl = new checkBoxListItem;
CONNECT( cb, stateChanged( int ), this, onUpdate() );
const char *help = module_get_help( p_parser ); const char *help = module_get_help( p_parser );
if( help != NULL ) checkbox_lists( qtr( module_GetLongName( p_parser ) ),
cb->setToolTip( formatTooltip( qtr( help ) ) ); help != NULL ? qtr( help ): "",
cbl->checkBox = cb; module_get_object( p_parser ) );
cbl->psz_module = strdup( module_get_object( p_parser ) );
modules.append( cbl );
if( p_item->value.psz && strstr( p_item->value.psz, cbl->psz_module ) ) \
cbl->checkBox->setChecked( true );
} }
void ModuleListConfigControl::checkbox_lists( QString label, QString help, const char* psz_module ) void ModuleListConfigControl::checkbox_lists( QString label, QString help, const char* psz_module )
......
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