Skip to content

fix(storage)!: Remove the stray Windows.Storage.ThumbnailMode - #25990

Merged
MartinZikmund merged 1 commit into
unoplatform:masterfrom
ramezgerges:dev/rara/remove-storage-thumbnailmode
Nov 4, 2026
Merged

MartinZikmund merged 1 commit into
unoplatform:masterfrom
ramezgerges:dev/rara/remove-storage-thumbnailmode

Conversation

@ramezgerges

Copy link
Copy Markdown
Contributor

GitHub Issue: closes #25479

PR Type:

🐞 Bugfix

What changed? 🚀

Uno declared a public Windows.Storage.ThumbnailMode enum (MusicView, VideosView) that WinRT doesn't have. The WinRT type is Windows.Storage.FileProperties.ThumbnailMode, which Uno also ships. A file importing both namespaces, a common pair (the WinUI Gallery StoragePickers sample uses it), didn't compile:

error CS0104: 'ThumbnailMode' is an ambiguous reference between 'Windows.Storage.FileProperties.ThumbnailMode' and 'Windows.Storage.ThumbnailMode'

(reproduced with the issue's project on Uno.WinRT 7.0.0-dev.2554)

  • Removed src/Uno.WinRT/Storage/ThumbnailMode.cs.
  • Removed its only user, a GetThumbnailAsync helper in StorageFile built on the old iOS MPMoviePlayerController, which sat in an #if false block and never compiled.
  • PackageDiffIgnore.xml: the type removal is listed in the 6.6 and 6.7 sets.
  • 7.0 migration guide: a bullet under "WinRT projection alignment (WinUI parity)" pointing to Windows.Storage.FileProperties.ThumbnailMode.

Validation

  • Uno.WinRT Generic, Reference and Wasm build with analyzers.
  • The issue's snippet (using Windows.Storage; using Windows.Storage.FileProperties; + ThumbnailMode.PicturesView) compiles against the newly built Uno.WinRT reference assembly; it fails with CS0104 against the published package.

PR Checklist ✅

Breaking change: the public Windows.Storage.ThumbnailMode type is removed. It isn't a WinRT type, so code using it didn't build on WinUI either; use Windows.Storage.FileProperties.ThumbnailMode.

🤖 Generated with Claude Code

WinRT has no Windows.Storage.ThumbnailMode, so a file importing both
Windows.Storage and Windows.Storage.FileProperties got CS0104 on
ThumbnailMode. Its only user was an #if false iOS thumbnail helper in
StorageFile, removed with it.

Fixes unoplatform#25479

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@github-actions github-actions Bot added area/build Categorizes an issue or PR as relevant to build infrastructure kind/documentation labels Nov 3, 2026
@unodevops

Copy link
Copy Markdown
Contributor

🤖 Your WebAssembly Sample App stage site is ready! Visit it here:

@unodevops

Copy link
Copy Markdown
Contributor

@MartinZikmund

Copy link
Copy Markdown
Member

@Mergifyio backport release/stable/7.0

@mergify

mergify Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

backport release/stable/7.0

✅ Backports have been created

Details

@MartinZikmund MartinZikmund added the 7.0 PRs only. For issues, use the Release field. label Nov 4, 2026
@MartinZikmund
MartinZikmund merged commit 16e2317 into unoplatform:master Nov 4, 2026
54 checks passed
@ramezgerges
ramezgerges deleted the dev/rara/remove-storage-thumbnailmode branch November 4, 2026 21:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

7.0 PRs only. For issues, use the Release field. area/build Categorizes an issue or PR as relevant to build infrastructure kind/documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows.Storage.ThumbnailMode is not a WinRT type and makes ThumbnailMode ambiguous with Windows.Storage.FileProperties

4 participants