1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-04-01 12:06:41 +00:00

Change the cell edit selection behaviour of the nested tables. Also auto-expand the enum delegate selections (both main table as well as nested table in the dialogue subview)

This commit is contained in:
cc9cii 2015-04-18 10:07:53 +10:00
parent f88be67556
commit 5e84858c0b
2 changed files with 3 additions and 0 deletions

View file

@ -444,6 +444,8 @@ void CSVWorld::EditWidget::remake(int row)
NestedTable* table = new NestedTable(mDocument, mNestedModels.back(), this); NestedTable* table = new NestedTable(mDocument, mNestedModels.back(), this);
// FIXME: does not work well when enum delegates are used // FIXME: does not work well when enum delegates are used
//table->resizeColumnsToContents(); //table->resizeColumnsToContents();
table->setEditTriggers(QAbstractItemView::CurrentChanged);
table->setSelectionBehavior(QAbstractItemView::SelectItems);
QLabel* label = QLabel* label =

View file

@ -88,6 +88,7 @@ void CSVWorld::EnumDelegate::setEditorData (QWidget *editor, const QModelIndex&
if (mValues[i].first==value) if (mValues[i].first==value)
{ {
comboBox->setCurrentIndex (i); comboBox->setCurrentIndex (i);
comboBox->showPopup();
break; break;
} }
} }