Refactored the logic to determine the data usage summary mark which now
correctly tests for null.
Bug: 30946416
Change-Id: Ida1281a771013fd807242f846edb4f2a9c0ccabb
Test: make RunSettingsRoboTests
Clicking the Data usage summary preference will open the same dialog
that billing cycle does to modify data warning level. The Dialog
was abstracted to be used outside of the Billing Cycle settings
fragment.
Test: Robo tests in next cherry-pick.
Change-Id: I70398d4656b6da4233b2bfa0da6ffa7402ead69b
Fixes: 26932938
(cherry picked from commit 9fad289ca9)
Created a new controller for DataUsageInfo and add appropriate
unit tests.
Bug: 30946416
Change-Id: Ida1281a771013fd807242f846edb4f2a9c0ccabb
Test: Robolectric tests with target RunSettingsRoboTests
Bug: 30681771
Test: SettingsUnitTests
Refactor visibility logging from InstrumentedFragment into a mixin. And
apply mixin in remaining fragments.
Change-Id: Ibbb59904336254a3e4bb9e8c7d0b36e5a6bc2622
Clicking the Data usage summary preference will open the same dialog
that billing cycle does to modify data warning level. The Dialog
was abstracted to be used outside of the Billing Cycle settings
fragment.
Change-Id: I70398d4656b6da4233b2bfa0da6ffa7402ead69b
Fixes: 26932938
The strings were complex to localize, especially since they used
formatting that needed to be carefully reconstructed for cases where
the amount of data appears in the middle of a string. Also, we
already had a localization for file sizes, which we should avoid
redoing, to minimize discrepancies.
Finally, we are now bidi wrapping the usage amount, as it may break
in the RTL locales otherwise, since the RTL locales may be using
Latin abbreviations for gigabyte etc that are LTR.
Since formatting needs to be applied to everything except the number
of units in the amount of data used, and markup should be avoided
since it will confuse bidi wrapping, the code carefully constructs
CharSequence templates that are then decorated with spans after
getting filled in.
Bug: 28747101
Change-Id: I18756b4de99eb551a51fe5e74d1c9cf505551f08
This partially reverts I5be9bb7ce3b11709117da698d6c03610f4e5e40e in
order to use existing localizations and also avoid hard to localize
strings.
Also, we now bidi wrap the usage value, since it may break in the RTL
locales otherwise.
Bug: 28747101
Change-Id: Ibc03632cccfe671164cfbb670a423ada1177db65
Update the UX and dig the data usage screen out of a huge whole of
technical debt. Switch every to use Preferences rather than standard
layouts and ListViews.
Split data usage into several fragments, all separated.
DataUsageSummary:
- Shows a summary of the 'default' usage at the top, this will be
the default sim on phones, or wifi if it has it, or ethernet
as last attempt to show something.
- Also has individual categories for each network type that has
data, cell, wifi, and ethernet. Maybe should look into bt though?
DataUsageList:
- Takes a NetworkTemplate as an input, and can only be reached from
the network specific categories in DataUsageSummary
- Shows a graph of current usage for that network and links to
app detail page for any app.
- Has gear link to quick get to billing cycle screen if available
BillingCycleSettings:
- Just a screen with the cycle day and warning/limits separated
out from the data usage.
AppDataUsage:
- App specific data usage details
- May need some UX iteration given lack of clarity in the spec
Bug: 22459566
Change-Id: I0222d8d7ea7b75a9775207a6026ebbdcce8f5e46