Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/treeview
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24004/src/net/sourceforge/bprocessor/gui/treeview
Modified Files:
GenericTreeView.java
Log Message:
New PencilTool implements a new algorithm to find surface. Currently not incremental
Index: GenericTreeView.java
===================================================================
RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/treeview/GenericTreeView.java,v
retrieving revision 1.66
retrieving revision 1.67
diff -C2 -d -r1.66 -r1.67
*** GenericTreeView.java 28 Nov 2006 15:39:35 -0000 1.66
--- GenericTreeView.java 30 Nov 2006 22:03:51 -0000 1.67
***************
*** 442,461 ****
/**
! * Insert the given object into the node
! * @param elem the elements
*/
! public void insertChildren(Collection elem) {
! final Comparator num =
! new Comparator() {
! public int compare(Object s1, Object s2) {
! return ((Entity) s1).getId().compareTo(((Entity) s2).getId());
! }
! };
! LinkedList sort = new LinkedList(elem);
! Collections.sort(sort, num);
! //insert
! int[] ins = new int[sort.size()];
int i = 0;
! Iterator iter = sort.iterator();
while (iter.hasNext()) {
this.add(new EntityNode(iter.next()));
--- 442,454 ----
/**
! * Insert a collection of Entity into this node
! * @param entities collection of Entity
*/
! public void insertChildren(Collection entities) {
! LinkedList sorted = new LinkedList(entities);
! Entity.sort(sorted);
! int[] ins = new int[sorted.size()];
int i = 0;
! Iterator iter = sorted.iterator();
while (iter.hasNext()) {
this.add(new EntityNode(iter.next()));
***************
*** 982,1000 ****
/**
! * Insert the given object into the node
! * @param elem the elements
*/
! public void insertChildren(Collection elem) {
! final Comparator num =
! new Comparator() {
! public int compare(Object s1, Object s2) {
! return ((Edge) s1).getId().compareTo(((Edge) s2).getId());
! }
! };
! LinkedList sort = new LinkedList(elem);
! Collections.sort(sort, num);
! int[] ins = new int[sort.size()];
int i = 0;
! Iterator iter = sort.iterator();
while (iter.hasNext()) {
Edge s = (Edge)iter.next();
--- 975,987 ----
/**
! * Insert collection of Entity in this node
! * @param entities collection of Entity
*/
! public void insertChildren(Collection entities) {
! LinkedList sorted = new LinkedList(entities);
! Entity.sort(sorted);
! int[] ins = new int[sorted.size()];
int i = 0;
! Iterator iter = sorted.iterator();
while (iter.hasNext()) {
Edge s = (Edge)iter.next();
|