When a file is renamed and then saved it is saved with the previous filename. Additionally, since commit afbad38a6de7a519a4aeabba42f8b48cdc2e3d4c the preview does not update with the new edited image(but still edits the original image).
- Open image a.jpg
- Rename image to b.jpg (F2)
- Edit it (Ctrl+L )
- Since afbad38a6de7a519a4aeabba42f8b48cdc2e3d4c the preview does not update
- Save (Ctrl+S)
- In all versions (from at least tag v17.08.3) now both a.jpg and b.jpg exist where the original filename (a.jpg) is the edited one.
So before afbad38a6de7a519a4aeabba42f8b48cdc2e3d4c both the selected image and the current url was incorrect (not updated), while after that commit the selected image is correct, but everything depending on currentUrl (editing, saving, full screen label, saveBar, ...) still gets the wrong image.
One contextManager->setCurrentUrl(newUrl) after the rename would make sure both are up to date.