Add no data usage string
Add a no data usage string so we can avoid showing incorrect dates when no data is available. Bug: 21076561 Change-Id: I4568cd750fe5f973fed0ff4ffa48412d8c6afd97
This commit is contained in:
@@ -516,6 +516,9 @@ public class InstalledAppDetails extends AppInfoBase
|
||||
private CharSequence getDataSummary() {
|
||||
if (mChartData != null) {
|
||||
long totalBytes = mChartData.detail.getTotalBytes();
|
||||
if (totalBytes == 0) {
|
||||
return getString(R.string.no_data_usage);
|
||||
}
|
||||
Context context = getActivity();
|
||||
return getString(R.string.data_summary_format,
|
||||
Formatter.formatFileSize(context, totalBytes),
|
||||
|
Reference in New Issue
Block a user