• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 package com.android.settings.fuelgauge.anomaly;
2 
3 import android.content.Context;
4 import android.support.v7.preference.Preference;
5 
6 import com.android.settings.R;
7 
8 /**
9  * Preference that stores {@link Anomaly}
10  */
11 public class AnomalyPreference extends Preference {
12     private Anomaly mAnomaly;
13 
AnomalyPreference(Context context, Anomaly anomaly)14     public AnomalyPreference(Context context, Anomaly anomaly) {
15         super(context);
16         mAnomaly = anomaly;
17 
18         if (anomaly != null) {
19             setTitle(anomaly.displayName);
20         }
21     }
22 
getAnomaly()23     public Anomaly getAnomaly() {
24         return mAnomaly;
25     }
26 
27 }
28