Bug 268925 - The editor 'forgets' one step when a crop is undone and redone
Summary: The editor 'forgets' one step when a crop is undone and redone
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Plugin-Editor-Crop (show other bugs)
Version: 2.0.0
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-20 01:13 UTC by JarD
Modified: 2017-08-06 19:13 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 2.0.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description JarD 2011-03-20 01:13:20 UTC
Version:           2.0.0 (using KDE 4.6.1) 
OS:                Linux

Whn to consecutive croppings have been done and undone, it is not possible to redo the second one. The editor showes the result of the first cropping instead of the second one.

Reproducible: Always

Steps to Reproduce:
- crop an image with 'proportional cropping' tool (set it to portrait)
- revert the change
- crop one more but this time with landscape setting
- undo the change
- redo the change (as if somebody tried to compare what the image looked like at the beginning and after the second change)

Actual Results:  
after the secong change has been undone and redone, the editor shows the result of the first change, i.e. portrait cropping as if the landscape cropping has never been done

Expected Results:  
The picture should look like it has after the second change (landscape cropping) has been made

OS: Linux (i686) release 2.6.35-28-generic
Compiler: cc
Comment 1 Marcel Wiesweg 2011-03-20 16:11:44 UTC
I can confirm. The problem is (much) more general though.
Comment 2 Marcel Wiesweg 2011-03-20 17:10:54 UTC
Git commit eee48d66d8164068df75afa61b1de0f1e7569c08 by Marcel Wiesweg.
Committed on 20/03/2011 at 17:09.
Pushed by mwiesweg into branch 'master'.

Properly remove files from cache with undo/redo

- ensure that cache files are cleared for redo actions when a new action is appended
- use only Qt code for file operations, removing C headers
- code reuse

BUG: 268925

M  +2    -7    NEWS     
M  +38   -59   utilities/imageeditor/canvas/undocache.cpp     
M  +14   -3    utilities/imageeditor/canvas/undocache.h     
M  +5    -16   utilities/imageeditor/canvas/undomanager.cpp     

http://commits.kde.org/digikam/eee48d66d8164068df75afa61b1de0f1e7569c08