Davejkane / riv

Riv - The Rust Image Viewer
MIT License
99 stars 10 forks source link

What is the behavior of `-m` on image deletion? #65

Closed gurgalex closed 5 years ago

gurgalex commented 5 years ago

A couple questions I've come across while adding tests and refactoring paths for #48

Scenerio 1

riv -m 50 "*.png"

The directory has 1000 png files in it but only 50 are shown.

program shows 50 of 50

Questions

  1. What should happen on image deletion/move?

Should the display show: 49 of 49

or, load in the next image, and show 50 of 50 (current development behavior)

  1. Should setting the max in command mode to the same 50 load in the next image that would have been shown? Display shows 50 of 50. (Like a refresh)

  2. What about adjusting the max to 100. Should that show 100 of 100 after the command completes?

  3. If the user sets the max to 10 and is on image 20 of 50 should the display refresh and show 10 of 10 or keep the current 20 of 50?

Davejkane commented 5 years ago

@gurgalex I think this is a reasonably niche issue and a bit of an edge case. It is worth thinking about, but I'm not going to turn this into a project issue just now. I don't have any strong opinions on the matter - as a user I don't think I'll be using the max feature often if at all - so I'm more than happy to let you decide what correctness should be in this case.

gurgalex commented 5 years ago

Alright, I'll settle on needing to refresh either the glob or change max images to load more images. Makes for simpler code.

On Sat, May 25, 2019, 03:24 Davejkane notifications@github.com wrote:

@gurgalex https://github.com/gurgalex I think this is a reasonably niche issue and a bit of an edge case. It is worth thinking about, but I'm not going to turn this into a project issue just now. I don't have any strong opinions on the matter - as a user I don't think I'll be using the max feature often if at all - so I'm more than happy to let you decide what correctness should be in this case.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Davejkane/riv/issues/65?email_source=notifications&email_token=AG5ANRGEHBAP77KSG5JCI43PXDZSVA5CNFSM4HPTQDKKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWHJ2NQ#issuecomment-495885622, or mute the thread https://github.com/notifications/unsubscribe-auth/AG5ANRELNK3JETAXRXFDOA3PXDZSVANCNFSM4HPTQDKA .