44 }; |
44 }; |
45 |
45 |
46 template<ldraw::Property Property> |
46 template<ldraw::Property Property> |
47 void Model::EditContext::setObjectProperty(const ldraw::id_t id, const ldraw::PropertyType<Property>& value) |
47 void Model::EditContext::setObjectProperty(const ldraw::id_t id, const ldraw::PropertyType<Property>& value) |
48 { |
48 { |
49 ldraw::Object* object = this->model().objectAt(id); |
49 ldraw::Object* object = this->model().findObjectById(id); |
50 if (object != nullptr) |
50 if (object != nullptr) |
51 { |
51 { |
52 object->setProperty<Property>(value); |
52 object->setProperty<Property>(value); |
53 modifiedObjects.insert(id); |
53 modifiedObjects.insert(id); |
54 } |
54 } |