[Bprocessor-commit] gui/src/net/sourceforge/bprocessor/gui/attrview AttributeView.java,1.24,1.25
Status: Pre-Alpha
Brought to you by:
henryml
|
From: Michael L. <he...@us...> - 2006-01-18 11:41:25
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/attrview In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv845/src/net/sourceforge/bprocessor/gui/attrview Modified Files: AttributeView.java Log Message: MoveTool: AXIS_RESTRICTED now default AttributeView: Updates when displayed object are changed Index: AttributeView.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/attrview/AttributeView.java,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** AttributeView.java 18 Jan 2006 10:12:39 -0000 1.24 --- AttributeView.java 18 Jan 2006 11:41:17 -0000 1.25 *************** *** 10,13 **** --- 10,14 ---- import net.sourceforge.bprocessor.model.Material; import net.sourceforge.bprocessor.model.Observer; + import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Selection; import net.sourceforge.bprocessor.model.Space; *************** *** 52,55 **** --- 53,57 ---- setPreferredSize(new Dimension(120, 240)); Selection.primary().addObserver(this); + Project.getInstance().addObserver(this); } *************** *** 66,71 **** } } repaint(); - //FIXME should re-display if anything else is changed } --- 68,76 ---- } } + Object current = ap.getCurrent(); + if (object == current) { + ap.display(current); + } repaint(); } *************** *** 97,100 **** --- 102,112 ---- /** + * Get current + * @return Current + */ + public Object getCurrent() { + return current; + } + /** * Display the construction space * @param o The object |