+ protected ComponentCompositionParams calculateCompositionParams()
+ {
+ ComponentCompositionParams params = new ComponentCompositionParams();
+ params.innerScale = getSubmodelScale();
+
+ List<GUIComponent> compList = submodelModifiable.getComponents();
+ Iterator<GUIComponent> componentIt = compList.iterator();
+ componentIt.next(); // Skip inner SubmodelInterface
+ InnerComponentParams[] comps = new InnerComponentParams[compList.size() - 1];
+ int i = 0;
+ while (componentIt.hasNext())
+ {
+ GUIComponent component = componentIt.next();
+ InnerComponentParams inner = new InnerComponentParams();
+ comps[i] = inner;
+ inner.params = component.getInstantiationParameters();
+ inner.pos = new Point(component.getPosX(), component.getPosY());
+ inner.name = component.getIdentifier();
+ i++;
+ }
+ params.subComps = comps;
+
+ List<GUIWire> wireList = submodelModifiable.getWires();
+ InnerWireParams wires[] = new InnerWireParams[wireList.size()];
+ i = 0;
+ for (GUIWire wire : wireList)