Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Added storage information for phones and tablets #16729

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

yaira2
Copy link
Member

@yaira2 yaira2 commented Jan 23, 2025

Resolved / Related Issues

To prevent extra work, all changes to the Files codebase must link to an approved issue marked as Ready to build. Please insert the issue number following the hashtag with the issue number that this Pull Request resolves.

Steps used to test these changes

Stability is a top priority for Files and all changes are required to go through testing before being merged into the repo. Please include a list of steps that you used to test this PR.

  1. Opened Files ...
  2. ...

@@ -1219,7 +1221,19 @@ await dispatcherQueue.EnqueueOrInvokeAsync(() =>
item.SyncStatusUI = CloudDriveSyncStatusUI.FromCloudDriveSyncStatus(syncStatus);
item.FileFRN = fileFRN;
item.FileTags = fileTag;
item.ContextualProperty = $"{Strings.Modified.GetLocalizedResource()}: {item.ItemDateModified}";

if (itemType.Equals("Generic hierarchical", StringComparison.Ordinal) && extraProperties is not null && extraProperties.Result["System.Capacity"] is not null && extraProperties.Result["System.FreeSpace"] is not null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This if works only when system (not Files's one) language is set to English. ItemType is translated by Windows

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was hoping @gave92 would know a better way to detect this 😂

@ferrariofilippo
Copy link
Contributor

I think we should show the used space even in the properties page. It should be easy now that we have those properties in ListedItem

@yaira2
Copy link
Member Author

yaira2 commented Jan 23, 2025

I think we should show the used space even in the properties page. It should be easy now that we have those properties in ListedItem

I think we can do this by setting the IsDriveRoot property. This will also enable the storage overview in the Details Pane.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature: Display smartphone/tablet storage size and free space
2 participants