mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-07 01:45:34 +00:00
Merge branch 'create-objects-menu' into 'master'
OpenMW-CS: Usability changes to the drop-down menu when creating a new object. See merge request OpenMW/openmw!1210
This commit is contained in:
commit
0ab8a7ddd7
1 changed files with 5 additions and 2 deletions
|
@ -22,6 +22,7 @@ CSVWorld::ReferenceableCreator::ReferenceableCreator (CSMWorld::Data& data, QUnd
|
||||||
std::vector<CSMWorld::UniversalId::Type> types = CSMWorld::UniversalId::listReferenceableTypes();
|
std::vector<CSMWorld::UniversalId::Type> types = CSMWorld::UniversalId::listReferenceableTypes();
|
||||||
|
|
||||||
mType = new QComboBox (this);
|
mType = new QComboBox (this);
|
||||||
|
mType->setMaxVisibleItems(20);
|
||||||
|
|
||||||
for (std::vector<CSMWorld::UniversalId::Type>::const_iterator iter (types.begin());
|
for (std::vector<CSMWorld::UniversalId::Type>::const_iterator iter (types.begin());
|
||||||
iter!=types.end(); ++iter)
|
iter!=types.end(); ++iter)
|
||||||
|
@ -32,6 +33,8 @@ CSVWorld::ReferenceableCreator::ReferenceableCreator (CSMWorld::Data& data, QUnd
|
||||||
static_cast<int> (id2.getType()));
|
static_cast<int> (id2.getType()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mType->model()->sort(0);
|
||||||
|
|
||||||
insertBeforeButtons (mType, false);
|
insertBeforeButtons (mType, false);
|
||||||
|
|
||||||
connect (mType, SIGNAL (currentIndexChanged (int)), this, SLOT (setType (int)));
|
connect (mType, SIGNAL (currentIndexChanged (int)), this, SLOT (setType (int)));
|
||||||
|
|
Loading…
Reference in a new issue