X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=org.simantics.g3d%2Fsrc%2Forg%2Fsimantics%2Fg3d%2Fscenegraph%2Fstructural%2FG3DStructuralParentNode.java;h=569f0211fdbb5f597d8476ce465b864b8595f9f1;hb=9f84331c9967c88e0e5550ce91f2b7e364a5cb6d;hp=073ef79d49b2b6c89f9f6ad3182a6f7959915753;hpb=da945733caf267fed4cf28206cc99f4f57fbd1e9;p=simantics%2F3d.git diff --git a/org.simantics.g3d/src/org/simantics/g3d/scenegraph/structural/G3DStructuralParentNode.java b/org.simantics.g3d/src/org/simantics/g3d/scenegraph/structural/G3DStructuralParentNode.java index 073ef79d..569f0211 100644 --- a/org.simantics.g3d/src/org/simantics/g3d/scenegraph/structural/G3DStructuralParentNode.java +++ b/org.simantics.g3d/src/org/simantics/g3d/scenegraph/structural/G3DStructuralParentNode.java @@ -12,6 +12,7 @@ package org.simantics.g3d.scenegraph.structural; import java.util.Collection; +import java.util.Objects; import javax.vecmath.Quat4d; import javax.vecmath.Vector3d; @@ -95,6 +96,9 @@ public abstract class G3DStructuralParentNode extends @Override @SetPropertyValue(G3D.URIs.hasPosition) public void setPosition(Vector3d position) { + if (Objects.equals(this.position, position)) + return; + this.position = position; firePropertyChanged(G3D.URIs.hasPosition); } @@ -102,6 +106,9 @@ public abstract class G3DStructuralParentNode extends @Override @SetPropertyValue(G3D.URIs.hasOrientation) public void setOrientation(Quat4d orientation) { + if (Objects.equals(this.orientation, orientation)) + return; + this.orientation = orientation; firePropertyChanged(G3D.URIs.hasOrientation); }