forked from len0rd/rockbox
Theme Editor: Stopped conditionals and sublines from triggering newlines and made combo boxes in config panel return text if not used in a conditional
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27184 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
5565a28c7d
commit
9d6b5d6317
3 changed files with 15 additions and 6 deletions
|
|
@ -208,6 +208,9 @@ QVariant DeviceState::data(QString tag, int paramCount,
|
|||
QPair<InputType, QWidget*> found =
|
||||
inputs.value(tag, QPair<InputType, QWidget*>(Slide, 0));
|
||||
|
||||
if(found.second == 0 && tag[0] == '?')
|
||||
found = inputs.value(tag.right(2), QPair<InputType, QWidget*>(Slide,0));
|
||||
|
||||
if(found.second == 0)
|
||||
return QVariant();
|
||||
|
||||
|
|
@ -226,7 +229,10 @@ QVariant DeviceState::data(QString tag, int paramCount,
|
|||
return dynamic_cast<QDoubleSpinBox*>(found.second)->value();
|
||||
|
||||
case Combo:
|
||||
return dynamic_cast<QComboBox*>(found.second)->currentIndex();
|
||||
if(tag[0] == '?')
|
||||
return dynamic_cast<QComboBox*>(found.second)->currentIndex();
|
||||
else
|
||||
return dynamic_cast<QComboBox*>(found.second)->currentText();
|
||||
|
||||
case Check:
|
||||
return dynamic_cast<QCheckBox*>(found.second)->isChecked();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue