diff options
author | Khalid Zubair <kzubair@cyngn.com> | 2015-11-24 09:42:29 -0800 |
---|---|---|
committer | Scott Mertz <scott@cyngn.com> | 2015-11-25 12:54:23 -0800 |
commit | bfefa433030c98a449b74e1538e4a9af04d6d76a (patch) | |
tree | db8e0a148b261e351862d51b0ded4e3e200b9767 /src/com | |
parent | 4536e5ce25f5214281550f4a21cbb83e3acfe598 (diff) | |
download | packages_apps_Settings-bfefa433030c98a449b74e1538e4a9af04d6d76a.zip packages_apps_Settings-bfefa433030c98a449b74e1538e4a9af04d6d76a.tar.gz packages_apps_Settings-bfefa433030c98a449b74e1538e4a9af04d6d76a.tar.bz2 |
perf: Enable app-profile pref only if profile has support
Use new perf manager APIs to query if a perf profile has support for
app profiles. Enable the pref only when supported.
Currently, only the 'Balanced' profile has app specific rules.
Change-Id: I9aa96bd869c6e80a4d3ba3b97646647db3b47d57
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/android/settings/fuelgauge/PowerUsageSummary.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/com/android/settings/fuelgauge/PowerUsageSummary.java b/src/com/android/settings/fuelgauge/PowerUsageSummary.java index 323a56c..d31bcff 100644 --- a/src/com/android/settings/fuelgauge/PowerUsageSummary.java +++ b/src/com/android/settings/fuelgauge/PowerUsageSummary.java @@ -463,6 +463,8 @@ public class PowerUsageSummary extends PowerUsageBase return; } mPerfProfilePref.setValue(String.valueOf(mPerf.getPowerProfile())); + mPerAppProfiles.setEnabled( + mPerf.getProfileHasAppProfiles(mPerf.getPowerProfile())); updatePerformanceSummary(); } |