WindowsAppSDK
WindowsAppSDK copied to clipboard
Allow UWP apps to get hidden folders and files inside an accessible folder
Proposal: Allow UWP apps to get hidden folders and files inside an accessible folder
Today GetFileAsync and GetFolderAsync will not work for hidden files. Please provide a way to get them since some apps may need them.
Summary
Modify GetFileAsync and GetFolderAsync to return hidden item instead of file not found. GetFilesAsync, GetFoldersAsync, and search query would not get affected and should not return hidden items.
Rationale
- Apps that need access to specific hidden items can do now
Scope
| Capability | Priority |
|---|---|
| This proposal will allow developers to access hidden items only if they know the name | Must |
| This proposal will allow developers to enumerate all hidden items in a folder | Won't |
@ptorr-msft - should we fold this into any of the existing file access asks?
Maybe enumeration support for hidden files can be added with a capability
@Jaiganeshkumaran ..FromApp APIs do work for hidden files. It seems what you are asking is these mentioned StorageFile/StorageFolder APIs to work as well.
@Jaiganeshkumaran Rewrite your proposal title with "Allow Storage APIs" instead of "Allow UWP apps" as most WinAPIs are Window types agnostic by design.
What is your motivation for using StorageFile?
For Trust Issues/Security, the less Full Trust app in usage the better. now please don't ask what's the motivation for security as well.
Side Note : The vast majority of windows desktop devs don't bother with AppContainer, because you guys haven't made the features they need; available to use within AppContainer. so they are forced to use Full Trust. It's astonishing to see that how you guys are ignoring/downplaying AppContainer/Security scenarios.
What is your motivation for using
StorageFile?
For me:
- StorageFile/Folder API has a safe Rust API: https://microsoft.github.io/windows-docs-rs/doc/windows/Storage/struct.StorageFolder.html#method.GetFilesAsync vs https://microsoft.github.io/windows-docs-rs/doc/windows/Win32/Storage/FileSystem/fn.FindFirstFileA.html
- Compare the developer experience for using the WinRT Storage API vs Win32 Storage API (not even async yet): https://learn.microsoft.com/en-us/windows/win32/fileio/listing-the-files-in-a-directory vs https://learn.microsoft.com/de-de/uwp/api/windows.storage.storagefolder.getfoldersasync?view=winrt-26100
So for now, I will tokio rather using the Windows API directly.
Why was it closed?
Hi, thank you for your question!
The Windows App SDK is focused on desktop-based project types and does not support UWP. We recommend checking out the new Microsoft.Windows.Storage.Pickers API, which may offer the functionality you're looking for.
If I understand it correctly, this API is not accessible via https://github.com/microsoft/windows-rs , but only via https://github.com/microsoft/windows-app-rs , isn't it? Sadly, the latter has been deprecated...