svn commit: r19590 - trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java

[email protected]
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: mvw
Date: 2011-07-18 23:37:39-0700
New Revision: 19590

Modified:
   trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java

Log:
Fix for issue 6297 - just a simple coding mistake made while adding UML 2 specific code.

Modified: trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java?view=diff&pathrev=19590&r1=19589&r2=19590
==============================================================================
--- trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java	(original)
+++ trunk/src/argouml-app/src/org/argouml/uml/diagram/state/StateDiagramGraphModel.java	2011-07-18 23:37:39-0700
@@ -1,6 +1,6 @@
 /* $Id$
  *****************************************************************************
- * Copyright (c) 2009 Contributors - see below
+ * Copyright (c) 2009-2011 Contributors - see below
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -8,6 +8,7 @@
  *
  * Contributors:
  *    bobtarling
+ *    Michiel van der Wulp
  *****************************************************************************
  *
  * Some portions of this file was previously release using the BSD License:
@@ -244,10 +245,11 @@
         getNodes().add(node);
 
         final Object stateMachine = getMachine();
-        if (Model.getFacade().getUmlVersion().startsWith("1")
-                && Model.getFacade().isAStateVertex(node)) {
-            Object top = Model.getStateMachinesHelper().getTop(stateMachine);
-            Model.getStateMachinesHelper().addSubvertex(top, node);
+        if (Model.getFacade().getUmlVersion().startsWith("1")) {
+            if (Model.getFacade().isAStateVertex(node)) {
+                Object top = Model.getStateMachinesHelper().getTop(stateMachine);
+                Model.getStateMachinesHelper().addSubvertex(top, node);
+            }
         } else {
             final List regions =
                 Model.getStateMachinesHelper().getRegions(stateMachine);

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=5905&dsMessageId=2797909

To unsubscribe from this discussion, e-mail: [[email protected]].
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.