inside display panel check if the property is part of the view provider

This commit is contained in:
wmayer
2018-09-19 21:30:35 +02:00
parent 047f91832b
commit 7fdbc1d2b8

View File

@@ -151,7 +151,11 @@ void DlgDisplayPropertiesImp::slotChangedObject(const Gui::ViewProvider& obj,
std::bind2nd(std::equal_to<Gui::ViewProvider*>(),
const_cast<Gui::ViewProvider*>(&obj)));
if (vp != Provider.end()) {
std::string prop_name = obj.getPropertyName(&prop);
const char* name = obj.getPropertyName(&prop);
// this is not a property of the view provider but of the document object
if (!name)
return;
std::string prop_name = name;
if (prop.getTypeId() == App::PropertyColor::getClassTypeId()) {
App::Color value = static_cast<const App::PropertyColor&>(prop).getValue();
if (prop_name == "ShapeColor") {