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

Commit 1a2306a2 authored by Adnan's avatar Adnan Committed by Danny Baumann
Browse files

QS: Make PerformanceProfile Tile respect locale change for label.

Change-Id: I5afaa0c0f468e3b79f5b22c4c2804463d7a16651
parent 39a1ce2d
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -46,7 +46,6 @@ public class PerformanceProfileTile extends QuickSettingsTile {
        mPm = (PowerManager) context.getSystemService(Context.POWER_SERVICE);

        Resources res = context.getResources();
        mEntries = res.getStringArray(com.android.internal.R.array.perf_profile_entries);
        mTypedArrayDrawables = res.obtainTypedArray(R.array.perf_profile_drawables);

        mPerfProfileDefaultEntry = mPm.getDefaultPowerProfile();
@@ -107,6 +106,8 @@ public class PerformanceProfileTile extends QuickSettingsTile {

    private synchronized void updateTile() {
        mDrawable = mTypedArrayDrawables.getResourceId(mCurrentValue, -1);
        Resources res = mContext.getResources();
        mEntries = res.getStringArray(com.android.internal.R.array.perf_profile_entries);
        mLabel = mEntries[mCurrentValue];
    }