Add API to get remaining lifetime as a percentage.
This differs slightly from the previous API, which exists for idle maintenance, whereas this value is intended to be displayed to users. First, it returns remaining lifetime, rather than used lifetime. Second, it rounds up the returned value for usabilty purposes. This isn't an issue on Pixel (which reports at 1% granularity), but devices which report at 10% granularity should show 100% out-of-box, which is not possible to distinguish in the old API. Bug: 309886423 Test: StorageManager.getRemainingStorageLifetime Change-Id: Ic5f6ec9969667302ba8bad95b2765e2cc740bed4
Loading
Please register or sign in to comment