Commit 9e49fb76 authored by Francois Cartegnie's avatar Francois Cartegnie

Qt: profiles: handle editable qcombobox values (fix #9723)

parent e954e55c
......@@ -675,6 +675,8 @@ void VLCProfileEditor::fillProfile( const QString& qs )
{
QComboBox *box = qobject_cast<QComboBox *>( object );
box->setCurrentIndex( box->findData( value ) );
if ( box->lineEdit() && box->currentIndex() == -1 )
box->lineEdit()->setText( value );
}
else if( object->inherits( "QLineEdit" ) )
{
......@@ -809,6 +811,7 @@ QString VLCProfileEditor::transcodeValue()
{
const QComboBox *box = qobject_cast<const QComboBox *>( object );
value = currentData( box ).toString();
if ( value.isEmpty() && box->lineEdit() ) value = box->lineEdit()->text();
}
else if( object->inherits( "QLineEdit" ) )
{
......
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