Shouldn't reset the material properties, when editing them.

--HG--
branch : gsoc2013-dfighter
hg/feature/gsoc2013-dfighter
dfighter1985 11 years ago
parent 37fb2cfcda
commit 6ad18a88f5

@ -67,6 +67,8 @@ namespace MaterialEditor
QString type = SMatProp::typeIdToString( mp.type ).c_str(); QString type = SMatProp::typeIdToString( mp.type ).c_str();
item->setData( 2, Qt::DisplayRole, type ); item->setData( 2, Qt::DisplayRole, type );
item->setData( 3, Qt::DisplayRole, mp.value.c_str() );
treeWidget->addTopLevelItem( item ); treeWidget->addTopLevelItem( item );
++itr; ++itr;
@ -102,6 +104,8 @@ namespace MaterialEditor
s = item->text( 2 ).toUtf8().data(); s = item->text( 2 ).toUtf8().data();
p.type = SMatProp::typeStringToId( s ); p.type = SMatProp::typeStringToId( s );
p.value = item->text( 3 ).toUtf8().data();
v.push_back( p ); v.push_back( p );
} }

Loading…
Cancel
Save