Bug 340937

Summary: Duplicate object widgets after copy and paste of messages into same diagram
Product: [Applications] umbrello Reporter: Ralf Habacker <ralf.habacker>
Component: generalAssignee: Umbrello Development Group <umbrello-devel>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: 2.14.3 (KDE Applications 4.14.3)   
Target Milestone: ---   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed In: 2.14.95 (KDE 14.11.95)
Sentry Crash Report:

Description Ralf Habacker 2014-11-13 19:00:35 UTC
After copy and paste of a message into the same sequence diagram, the message is connected to duplicated objects, not the original

Reproducible: Always

Steps to Reproduce:
1. start umbrello
2. create a sequence diagram
3. add two objects and a message between both objects
4. select the message and copy/paste it into the same diagram
5. select the objects and move them to the right or left

Actual Results:  
The pasted message is connected to two newly inserted objects, not to the original objects.

Expected Results:  
The pasted message should be connected to the original objects and no duplicated objects should be inserted.
Comment 1 Ralf Habacker 2014-11-13 19:45:00 UTC
Git commit aeaa3ea22c1ed1270fcc15ad2e94671def6644c8 by Ralf Habacker.
Committed on 13/11/2014 at 19:37.
Pushed by habacker into branch 'Applications/14.12'.

Fix bug 'Duplicate object widgets after copy and paste of messages into same diagram'.

The bug is fixed by comparing the paste scene id with the source diagram
and to skip object widget creating if the id's are equal.
FIXED-IN:14.11.95

M  +1    -1    umbrello/clipboard/umlclipboard.cpp
M  +28   -13   umbrello/clipboard/umldragdata.cpp
M  +3    -2    umbrello/clipboard/umldragdata.h

http://commits.kde.org/umbrello/aeaa3ea22c1ed1270fcc15ad2e94671def6644c8