Jorixon / JASM

Just Another Skin Manager
GNU General Public License v3.0
148 stars 16 forks source link

Thumbnail Path issues #201

Open CazzoPMX opened 3 months ago

CazzoPMX commented 3 months ago

Describe the bug Recently it seems that setting a Thumbnail with Whitespace in its name is not working properly.

To Reproduce Steps to reproduce the behavior:

  1. Assume a picture file named "toggle key.jpg" existing in the mods folder
    • It does not matter if the Mod had a thumbnail before or not
  2. Click on the "Set thumbnail" button of the mod
  3. Select said file -- Shows up properly
  4. Click "Save Mod"
  5. It now shows an empty Thumbnail which persists as such when switching, so it did save a new Path as expected.

Expected behavior Thumbnail being updated properly.

Desktop (please complete the following information):

Additional context Looking into the ModConfig File, the "ImagePath" Property is now recorded as "toggle%20key.jpg", which does not refer to an existing file - Manually changing the name back to what it should be works as expected and stays as such.

Additionally, if such a file (with whitespace) is selected from within an archive during the "Add new mod" popup, then it will just fail to recognize the update and stay on the automatically selected thumbnail (if any) and discarding the reselected one instead of overwriting it.