Simplify getting nestable pointer in BaseNestableTransformNode::toVariantMap

This commit is contained in:
sabrina-shanman 2019-08-05 09:51:45 -07:00
parent f188a3589e
commit 27cf080ad6

View file

@ -49,14 +49,12 @@ public:
QVariantMap toVariantMap() const {
QVariantMap map;
if (!_spatiallyNestable.expired()) {
auto nestable = _spatiallyNestable.lock();
if (nestable) {
map["parentID"] = nestable->getID();
map["parentJointIndex"] = _jointIndex;
map["baseParentScale"] = vec3toVariant(_baseScale);
}
auto nestable = _spatiallyNestable.lock();
if (nestable) {
map["parentID"] = nestable->getID();
map["parentJointIndex"] = _jointIndex;
map["baseParentScale"] = vec3toVariant(_baseScale);
}
return map;