Make battery info configurable and enable it by default
Change-Id: If38db229e420e9f7c0ac26abb42a2a309b2f87c2
This commit is contained in:
parent
da270f9fa1
commit
32537c0cfb
2 changed files with 5 additions and 1 deletions
|
|
@ -26,6 +26,9 @@
|
|||
<item>com.android.localtransport/.LocalTransport</item>
|
||||
</string-array>
|
||||
|
||||
<!-- Show battery information -->
|
||||
<bool name="config_show_battery_info" translatable="false">true</bool>
|
||||
|
||||
<!-- Whether to show peak refresh rate in display settings -->
|
||||
<bool name="config_show_peak_refresh_rate_switch">false</bool>
|
||||
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ import android.content.Context;
|
|||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.android.settings.R;
|
||||
import com.android.settings.fuelgauge.batterytip.BatteryTipPolicy;
|
||||
import com.android.settings.fuelgauge.batterytip.detectors.LowBatteryDetector;
|
||||
import com.android.settings.fuelgauge.batterytip.tips.BatteryTip;
|
||||
|
|
@ -42,7 +43,7 @@ public class BatterySettingsFeatureProviderImpl implements BatterySettingsFeatur
|
|||
|
||||
@Override
|
||||
public boolean isBatteryInfoEnabled(Context context) {
|
||||
return false;
|
||||
return context.getResources().getBoolean(R.bool.config_show_battery_info);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue