[Bprocessor-commit] gl/src/net/sourceforge/bprocessor/gl/tool Pencil.java, 1.8, 1.9
Status: Pre-Alpha
Brought to you by:
henryml
From: Nordholt <nor...@us...> - 2006-07-25 13:12:40
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24198/src/net/sourceforge/bprocessor/gl/tool Modified Files: Pencil.java Log Message: pencil stops drawing on existing edges and vertices Index: Pencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/Pencil.java,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** Pencil.java 21 Jul 2006 12:48:12 -0000 1.8 --- Pencil.java 25 Jul 2006 13:12:34 -0000 1.9 *************** *** 11,17 **** --- 11,20 ---- import java.awt.event.MouseEvent; import java.util.LinkedList; + import java.util.Collection; import java.util.List; import net.sourceforge.bprocessor.gl.GLView; + import net.sourceforge.bprocessor.gl.model.Intersection; + import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Edge; *************** *** 54,60 **** current = findIntersection(e); if (current != null) { - updateFeedback(); updateConstructors(); ! } } --- 57,63 ---- current = findIntersection(e); if (current != null) { updateConstructors(); ! updateFeedback(); ! } } *************** *** 73,78 **** if (start == null) { start = current; ! } else { ! if (start.vertex().equalEps(current.vertex())) { cleanUp(); --- 76,80 ---- if (start == null) { start = current; ! } else { if (start.vertex().equalEps(current.vertex())) { cleanUp(); *************** *** 85,89 **** start = current; incident = null; ! if (insertEdges(edges)) { cleanUp(); return; --- 87,97 ---- start = current; incident = null; ! Collection vColl = Project.getInstance().getVertices(); ! Collection eColl = Project.getInstance().getEdges(); ! boolean exsGeometry = ((current.type() == Intersection.VERTEX && ! vColl.contains(current.object())) || ! (current.type() == Intersection.EDGE && ! eColl.contains(current.object()))); ! if (insertEdges(edges) || exsGeometry) { cleanUp(); return; *************** *** 100,103 **** --- 108,112 ---- */ protected void dragged(MouseEvent e) { + } |