Bug 373308 - Connection between activity and pin does not end on pin
Summary: Connection between activity and pin does not end on pin
Status: RESOLVED FIXED
Alias: None
Product: umbrello
Classification: Applications
Component: general (show other bugs)
Version: Git
Platform: Other All
: NOR normal
Target Milestone: ---
Assignee: Umbrello Development Group
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-12-05 19:26 UTC by Ralf Habacker
Modified: 2017-05-25 09:01 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 2.21.80 (KDE Applications 17.03.80)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ralf Habacker 2016-12-05 19:26:20 UTC
After connecting a pin with an activity the association is not drawn between the pin and the activity. It ends in empty diagram space.

How to reproduce:
1. Add an activity diagram
2. Add two activities
3. Add a pin to the first activity 
4. Connect the pin with the second activity

The association does not connect the pin with the activity.

Same with ports and components.

The bug seems to be introduced with fixing of bug 371990 (commit 536e52fe6f71145cdcee16b5833f1c73b64e61fa)
Comment 1 Ralf Habacker 2016-12-06 16:39:37 UTC
My initial estimation of the related commit was wrong. Retesting on another machine shows that this happens on git master branch. The related commit is
703b25a024380dcb81895c9700c3a8d4d72cfb74 which adds pin and ports as QGraphicsItem child to the component or activity widget. My guess of the root cause is that fetching the position of the child widget with pos() returns the position relativ to the parent item. So fix this on the related locations it is required to use QGraphicsItem::scenePos() instead for example instead widget->x() it is required to use widget->scenePos().x()
Comment 2 Ralf Habacker 2016-12-06 17:15:51 UTC
Git commit 95a1547793bba6519ca7f277ccc1d218f8d871d5 by Ralf Habacker.
Committed on 06/12/2016 at 17:15.
Pushed by habacker into branch 'master'.

Fix 'Connection between activity and pin does not ends on pin'.

FIXED-IN:2.21.80 (KDE Applications 17.03.80)

M  +2    -2    umbrello/toolbarstateassociation.cpp
M  +6    -6    umbrello/umlwidgets/associationwidget.cpp

https://commits.kde.org/umbrello/95a1547793bba6519ca7f277ccc1d218f8d871d5