d2phap / ImageGlass

🏞 A lightweight, versatile image viewer
https://imageglass.org
Other
7.36k stars 482 forks source link

Extension icons don't work with Microsoft Store version #1847

Open nicoco007 opened 6 months ago

nicoco007 commented 6 months ago

System information:

To Reproduce

Steps to reproduce the behavior:

  1. Uninstall regular version of ImageGlass
  2. Install ImageGlass from Microsoft Store
  3. Go to Settings > File type associations and press "Make default"

Actual behavior:

Icons in Windows Explorer flicker, indicating something changed, but all registered files still use ImageGlass's logo. If I go to default apps settings, not all extensions are assigned to ImageGlass either, although that seems to be the case with the regular version as well. Pressing "Remove default" then "Make default" again doesn't help.

Expected behavior:

Image thumbnails use extension-specific icons.

Screenshots:

image

Additional context:

Reinstalling the regular version makes the icons show up as expected.

I think this is related to how Microsoft Store apps store settings in the registry. In the HKEY_CURRENT_USER\Software\RegisteredApplications key, I see a value AppXkycr36dyt7aej1hsxnvpn7vnn8w7m0je set to Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppModel\Repository\Packages\9662DuongDieuPhap.ImageGlass_9.0.11.0_x64__xjrmsrdc1fgj6\IMAGEGLASS\Capabilities, which is very different from what ImageGlass is doing over here. There's also a value called 9662DuongDieuPhap.ImageGlass_xjrmsrdc1fgj6!IMAGEGLASS in PackagedApps set to the same path.

mojoZHU commented 3 months ago

I seem to have also reproduced this issue on the "portable" version that isn't installed with the msi file. No matter what I try, the icons won't appear. I have also tried manually associating them, but this seems to apply the same icon for all file types and not for individual file types