Bug 363008

Summary: No undo of associations possible
Product: [Applications] umbrello Reporter: Ralf Habacker <ralf.habacker>
Component: generalAssignee: Umbrello Development Group <umbrello-devel>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: 2.19.1 (KDE Applications 16.04.1)   
Target Milestone: ---   
Platform: Other   
OS: All   
See Also: https://bugs.kde.org/show_bug.cgi?id=359012
Latest Commit: Version Fixed In: 2.28.80 (KDE Applications 19.07.80)

Description Ralf Habacker 2016-05-13 08:42:46 UTC
It is not possible to undo an added connection.  Undoing removes the latest class before adding the connection.
 

Reproducible: Always

Steps to Reproduce:
1. start umbrello
2. add a classes
3. add another class
4. connect them with an association
5. press undo in the menu or press STRG-Z

Actual Results:  
The class added in 3. has been removed from the scene, not the connection. 

Expected Results:  
The connection should be undo'd.
Comment 1 Ralf Habacker 2019-07-16 05:11:05 UTC
Git commit 4c8b03243e276689c8dc0c3f4e01c65f727c1bb9 by Ralf Habacker.
Committed on 16/07/2019 at 05:10.
Pushed by habacker into branch 'Applications/19.08'.

Add undo support for association widgets

It was necessary to enlarge CmdBaseWidgetCommand and derived classes
with an additional AssociationWidget pointer, since the WidgetBase class
misses some methods to be usable as a common class for all widget types
and association widgets are implemented differently in the UMLscene class.
FIXED-IN:2.28.80 (KDE Applications 19.07.80)

M  +81   -8    umbrello/cmds/widget/cmdbasewidgetcommand.cpp
M  +9    -0    umbrello/cmds/widget/cmdbasewidgetcommand.h
M  +47   -12   umbrello/cmds/widget/cmdcreatewidget.cpp
M  +3    -1    umbrello/cmds/widget/cmdcreatewidget.h
M  +45   -18   umbrello/cmds/widget/cmdremovewidget.cpp
M  +2    -0    umbrello/cmds/widget/cmdremovewidget.h
M  +2    -10   umbrello/toolbarstateassociation.cpp
M  +11   -1    umbrello/umlscene.cpp
M  +1    -0    umbrello/umlscene.h

https://commits.kde.org/umbrello/4c8b03243e276689c8dc0c3f4e01c65f727c1bb9