X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.scenegraph%2Fsrc%2Forg%2Fsimantics%2Fscenegraph%2Fg2d%2FIG2DNode.java;h=2d17e47c594fbc2ad546106a2a0d6c9777bd7d95;hp=e181d59ff02d45305da28dbbac3cb7802be5b002;hb=512d469c3e490cdfc9a10fbbd6efe92ae6c0358a;hpb=afee96f637a9563364343ec9688b1d4b3aa98a10 diff --git a/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/IG2DNode.java b/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/IG2DNode.java index e181d59ff..2d17e47c5 100644 --- a/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/IG2DNode.java +++ b/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/IG2DNode.java @@ -50,8 +50,9 @@ public interface IG2DNode extends INode, IEventHandler { public boolean validate(); /** - * Perform the actual rendering. Node state changes should be avoided in - * this method. This method should not change the transform of the g2d + * Perform the actual rendering. Node state changes must be avoided in + * this method. Implement node state changes to refresh method instead. + * This method should not change the transform of the g2d * instance. You should call g2d.create or copy the original transform and * put it back at the end of this method according to what is specified in * {@link Graphics2D#setTransform(AffineTransform)}. @@ -70,7 +71,12 @@ public interface IG2DNode extends INode, IEventHandler { * @see #getTransform() */ public void render(Graphics2D g2d); - + + /** + * Refresh the node state. + */ + public void refresh(); + /** * Visit the IG2DNode substructure of this node using the provided visitor. *