Make sure, a newly saved image is selected in ContextManager
Summary:
After an image is Saved As... in View Mode, the current image
and selection in thumbnail bar are not updated. As a side effect the
view jumps to the first item in directory instead of showing the newly
saved image. This is caused by D8934.
This patch makes sure, the new image is selected in ContextManager
and the window title is updated correctly.
Test Plan:
- Open an image in View Mode
- Use File → Save As and save image as e.g. "filename2.jpg"
- Image "filename2.jpg" should be viewed and window title updated
- Check that File → Save As also works correctly after image modifications (resize, crop, etc.)
- Check with option Keep same zoom and position and 100% or a custom zoom factor active
- Check current selection while toggling between View/Browse Mode after File → Save As
- Check that Go back to the original works
- (Some more special tests in D9342)
Reviewers: rkflx, Gwenview
Reviewed By: rkflx, Gwenview
Subscribers: bschiffner, ngraham
Differential Revision: https://phabricator.kde.org/D9342