svn commit: r14886 - trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java

[email protected]
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: bobtarling
Date: 2008-06-08 05:25:58-0700
New Revision: 14886

Modified:
   trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java

Log:


Modified: trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java?view=diff&rev=14886&p1=trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java&p2=trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java&r1=14885&r2=14886
==============================================================================
--- trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java	(original)
+++ trunk/src/argouml-core-diagrams-sequence2/src/org/argouml/uml/diagram/sequence2/ui/ModePlaceClassifierRole.java	2008-06-08 05:25:58-0700
@@ -60,10 +60,15 @@
 
     
     private void  postProcessing() {
+        // _pers is the FigClassifierRole we're trying to place
         int y = _pers.getY();
         Layer lay = editor.getLayerManager().getActiveLayer();
         List nodes = lay.getContentsNoEdges();
-        // It's 1 because super has created the node
+        // Get the first existing FigNode and if it exists set the
+        // y position of _pers to be the same as it.
+        // TODO: What if the first node is not a FigClassifierRole but is a
+        // FigComment. Make this safe for that.
+        // TODO: We should also fix height as well as y position here.
         if (nodes.size() > 0) {
             Fig fig = (Fig) nodes.get(0);
             if (fig != _pers) {
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.