Page 1 of 1

Discard edits for first/last file in folder

Posted: Sun Apr 23, 2023 3:36 pm
by FKCapitalism2
If you open first file in folder (left arrow key will not move to another image) then adjust e.g. curves and then press left arrow on keyboard you see dialog to asking you to save the settings, if you select "no" popup window will close however if you press left arrow again it will make the dialog come up again and again endlessly.

Same bug for last file in the folder + right arrow key.

Re: Discard edits for first/last file in folder

Posted: Sun Apr 23, 2023 3:44 pm
by user0
+1

Re: Discard edits for first/last file in folder

Posted: Wed May 03, 2023 6:26 am
by xnview
why it ask if you want to save the file??

Re: Discard edits for first/last file in folder

Posted: Wed May 03, 2023 7:00 am
by FKCapitalism2
xnview wrote: Wed May 03, 2023 6:26 am why it ask if you want to save the file??
Because made adjustment in Image > Ajust > Curves or did any other changes that require saving.

Re: Discard edits for first/last file in folder

Posted: Wed May 03, 2023 7:08 am
by user0
xnview wrote: Wed May 03, 2023 6:26 am why it ask if you want to save the file??
file is dirty

As far as I can see, OP reports the behavior that happens when you click the "No" button, but I'd call it "unpolished behavior" and not a bug.

it happens when open and modify:
- single file in folder and move any direction from it
- first file in folder and move to the prev file
- last file in folder and move to the next file

"Save changed file" dialog will popup
first_last_file_save_dialog.png
first_last_file_save_dialog.png (6.73 KiB) Viewed 433 times

Existing behaviour
when you press No:
- file will not saved (as expected)
- tab will have the same file openned (as expected)
- file will still have all unsaved changes (dirty state) - this is the reporting issue

Desired behaviour
when you press No:
- file will not saved (same)
- tab will have the same file openned (same)
- file shall revert to its original state (all changes abandoned unsaved, dirty=false)

Why? Because you have:
- moved away from existing modified file (pressed ← / → or scrolled)
- pressed No in save dialog, confirming you do not want to keep changes
and asking to save changes again (eg when you press Esc or arrows/scroll) is a bit annoying to my taste