[umbrello] [Bug 403515] Ports on component diagram are randomly disappeared

Ralf Habacker bugzilla_noreply at kde.org
Thu Jan 24 22:02:21 GMT 2019


https://bugs.kde.org/show_bug.cgi?id=403515

--- Comment #3 from Ralf Habacker <ralf.habacker at freenet.de> ---
Created attachment 117647
  --> https://bugs.kde.org/attachment.cgi?id=117647&action=edit
Working testcase with single component diagram and three ports

The comparison of this file with the faulty file shows that there are missing
<portwidget> tags in the xmi file.

It is possible to do this by manually editing the xmi file or by adding a
correction method when loading a file. 

For manual editing, test.xmi can be used as an example for the mapping.

A corresponding correction function should be included in UMLScenePrivate (for
example fixupPorts()) and should be called at the end of
UMLScene::loadFromXMI1() for component diagrams. The implementation should do
the following:
1. iterate over all component widgets (UMLScene::widgetList())
1.1. get the corresponding UML component instance (by UMLWidget::umlObject())
1.2. get the corresponding ports (UMLComponent::containedObjects())
1.3 iterate over all UMLPort instances 
1.3.1 find corresponding port widget by comparing UMLObject::id() with
UMLWidget::id()
If no widget is available, it would have to be created with the component
widget as parent.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the umbrello-devel mailing list