Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a9db1aa3 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix crash when tapping on cell icon in QS." into nyc-mr1-dev

parents ddb980de 00ff604a
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@

package com.android.systemui.qs.tiles;

import android.annotation.ColorInt;
import android.content.Context;
import android.content.res.Configuration;
import android.content.res.Resources;
@@ -65,7 +66,7 @@ public class DataUsageDetailView extends LinearLayout {
        final Resources res = mContext.getResources();
        final int titleId;
        final long bytes;
        int usageColor = 0;
        @ColorInt int usageColor = 0;
        final String top;
        String bottom = null;
        if (info.usageLevel < info.warningLevel || info.limitLevel <= 0) {
@@ -90,7 +91,7 @@ public class DataUsageDetailView extends LinearLayout {
                    formatBytes(info.usageLevel));
            bottom = res.getString(R.string.quick_settings_cellular_detail_data_limit,
                    formatBytes(info.limitLevel));
            usageColor = R.color.system_warning_color;
            usageColor = mContext.getColor(R.color.system_warning_color);
        }

        if (usageColor == 0) {
@@ -101,7 +102,7 @@ public class DataUsageDetailView extends LinearLayout {
        title.setText(titleId);
        final TextView usage = (TextView) findViewById(R.id.usage_text);
        usage.setText(formatBytes(bytes));
        usage.setTextColor(mContext.getColor(usageColor));
        usage.setTextColor(usageColor);
        final DataUsageGraph graph = (DataUsageGraph) findViewById(R.id.usage_graph);
        graph.setLevels(info.limitLevel, info.warningLevel, info.usageLevel);
        final TextView carrier = (TextView) findViewById(R.id.usage_carrier_text);