[Bprocessor-commit] gui/src/net/sourceforge/bprocessor/gui/attrview ClassificationTextAttribute.jav
Status: Pre-Alpha
Brought to you by:
henryml
From: Michael L. <he...@us...> - 2007-12-13 12:00:58
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/attrview In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv20795/src/net/sourceforge/bprocessor/gui/attrview Modified Files: ClassificationTextAttribute.java LinkAttribute.java Log Message: Major change wrt Space/Container Index: ClassificationTextAttribute.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/attrview/ClassificationTextAttribute.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ClassificationTextAttribute.java 9 Aug 2007 16:07:48 -0000 1.10 --- ClassificationTextAttribute.java 13 Dec 2007 12:00:55 -0000 1.11 *************** *** 40,44 **** import net.sourceforge.bprocessor.model.Classification; import net.sourceforge.bprocessor.model.Project; ! import net.sourceforge.bprocessor.model.Space; import net.sourceforge.bprocessor.model.Structure; --- 40,44 ---- import net.sourceforge.bprocessor.model.Classification; import net.sourceforge.bprocessor.model.Project; ! import net.sourceforge.bprocessor.model.Container; import net.sourceforge.bprocessor.model.Structure; *************** *** 318,327 **** Vector cur = ((Structure) attribute.getValue()).getChildren(); if (attribute.getValue() instanceof Classification) { ! if (((Classification) attribute.getValue()).getType() == Space.CONSTRUCTION) { cur.addAll(Project.getInstance().getClassification("-99", ! Space.CONSTRUCTION).getChildren()); ! } else if (((Classification) attribute.getValue()).getType() == Space.FUNCTIONAL) { cur.addAll(Project.getInstance().getClassification("-99", ! Space.FUNCTIONAL).getChildren()); } else { log.warn(((Classification) attribute.getValue()).getType() + " is a unknown type"); --- 318,327 ---- Vector cur = ((Structure) attribute.getValue()).getChildren(); if (attribute.getValue() instanceof Classification) { ! if (((Classification) attribute.getValue()).getType() == Container.CONSTRUCTION) { cur.addAll(Project.getInstance().getClassification("-99", ! Container.CONSTRUCTION).getChildren()); ! } else if (((Classification) attribute.getValue()).getType() == Container.FUNCTIONAL) { cur.addAll(Project.getInstance().getClassification("-99", ! Container.FUNCTIONAL).getChildren()); } else { log.warn(((Classification) attribute.getValue()).getType() + " is a unknown type"); Index: LinkAttribute.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/attrview/LinkAttribute.java,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** LinkAttribute.java 14 Apr 2007 15:00:42 -0000 1.17 --- LinkAttribute.java 13 Dec 2007 12:00:55 -0000 1.18 *************** *** 37,41 **** import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Selection; ! import net.sourceforge.bprocessor.model.Space; /** --- 37,41 ---- import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Selection; ! import net.sourceforge.bprocessor.model.Container; /** *************** *** 174,179 **** JLabel valueLabel; if (value instanceof Entity) { ! if (value instanceof Space) { ! s = ((Space)value).getDisplayName(); } else { s = ((Entity)value).getName(); --- 174,179 ---- JLabel valueLabel; if (value instanceof Entity) { ! if (value instanceof Container) { ! s = ((Container)value).getDisplayName(); } else { s = ((Entity)value).getName(); *************** *** 410,414 **** new Comparator() { public int compare(Object s1, Object s2) { ! return ((Space) s1).getName().compareToIgnoreCase(((Space) s2).getName()); } }; --- 410,414 ---- new Comparator() { public int compare(Object s1, Object s2) { ! return ((Container) s1).getName().compareToIgnoreCase(((Container) s2).getName()); } }; *************** *** 417,421 **** new Comparator() { public int compare(Object s1, Object s2) { ! return ((Space) s1).getId().compareTo(((Space) s2).getId()); } }; --- 417,421 ---- new Comparator() { public int compare(Object s1, Object s2) { ! return ((Container) s1).getId().compareTo(((Container) s2).getId()); } }; *************** *** 427,431 **** Iterator it = sort.iterator(); while (it.hasNext()) { ! Space current = (Space) it.next(); String name = current.getName() + "-" + current.getId().toString(); if (name.startsWith(string) && !name.equalsIgnoreCase(string)) { --- 427,431 ---- Iterator it = sort.iterator(); while (it.hasNext()) { ! Container current = (Container) it.next(); String name = current.getName() + "-" + current.getId().toString(); if (name.startsWith(string) && !name.equalsIgnoreCase(string)) { |