use names directly from document to set them in scene inspector

This commit is contained in:
wmayer
2017-01-30 22:29:26 +01:00
parent 250b98a07c
commit 45198fb712
5 changed files with 73 additions and 38 deletions

View File

@@ -190,14 +190,6 @@ void ViewProviderDocumentObject::attach(App::DocumentObject *pcObj)
void ViewProviderDocumentObject::updateData(const App::Property* prop)
{
if (pcObject && prop == &pcObject->Label) {
// SoBase::setName() replaces characters that according to the
// VRML standard are invalid. To avoid the replacement we use
// the percent encoding.
QByteArray ba(pcObject->Label.getValue());
QByteArray name = ba.toPercentEncoding();
pcRoot->setName(name.constData());
}
ViewProvider::updateData(prop);
}