Category breakdown size should match total size.
The system apps' base size was not being properly attributed to the system. This was causing the storage to go totally unattributed (and causing roughly a 1GB gap in sizes.) On my test device, the sizes now sum properly. Change-Id: Ibc13015e40f854090a7a3ec09eef4c5c52918e0f Fixes: 35144717 Test: Settings robo
This commit is contained in:
@@ -89,6 +89,8 @@ public class StorageAsyncLoader
|
||||
// code size.
|
||||
if (!app.isSystemApp() || app.isUpdatedSystemApp()) {
|
||||
attributedAppSizeInBytes += stats.getCodeBytes();
|
||||
} else {
|
||||
result.systemSize += stats.getCodeBytes();
|
||||
}
|
||||
switch (app.category) {
|
||||
case CATEGORY_GAME:
|
||||
@@ -117,6 +119,7 @@ public class StorageAsyncLoader
|
||||
public long gamesSize;
|
||||
public long musicAppsSize;
|
||||
public long otherAppsSize;
|
||||
public long systemSize;
|
||||
public StorageStatsSource.ExternalStorageStats externalStats;
|
||||
}
|
||||
|
||||
|
||||
@@ -181,7 +181,7 @@ public class StorageItemPreferenceController extends PreferenceController {
|
||||
mGamePreference.setStorageSize(data.gamesSize);
|
||||
mAppPreference.setStorageSize(data.otherAppsSize);
|
||||
if (mSystemPreference != null) {
|
||||
mSystemPreference.setStorageSize(mSystemSize);
|
||||
mSystemPreference.setStorageSize(mSystemSize + data.systemSize);
|
||||
}
|
||||
|
||||
long unattributedBytes = data.externalStats.totalBytes - data.externalStats.audioBytes
|
||||
|
||||
Reference in New Issue
Block a user