Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv2889/src/net/sourceforge/bprocessor/gl/tool
Modified Files:
FinalMoveTool.java
Log Message:
Changed InstanceMover to use the systemFor static method for creating a coordinatesystem
Index: FinalMoveTool.java
===================================================================
RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/FinalMoveTool.java,v
retrieving revision 1.35
retrieving revision 1.36
diff -C2 -d -r1.35 -r1.36
*** FinalMoveTool.java 23 Nov 2007 10:27:56 -0000 1.35
--- FinalMoveTool.java 26 Nov 2007 10:30:53 -0000 1.36
***************
*** 216,221 ****
// convert the handle into the coordinatesystems of the surface and translate
//the instance anchor according to that
! Surface onto = (Surface)current.object();
! CoordinateSystem cs = onto.coordinateSystem().plane().coordinateSystem();
CoordinateSystem anchor = instance.getInstanceAnchor();
anchor.setAttributes(cs.getAttributes());
--- 216,226 ----
// convert the handle into the coordinatesystems of the surface and translate
//the instance anchor according to that
! Surface surface = (Surface)current.object();
! Vertex n = surface.normal();
! Vertex origin = surface.getFirstVertex();
! if (!editor.getView().facingFront(surface)) {
! n = n.scale(-1);
! }
! CoordinateSystem cs = CoordinateSystem.systemFor(origin, n);
CoordinateSystem anchor = instance.getInstanceAnchor();
anchor.setAttributes(cs.getAttributes());
|