Merge "Create separate On/Off string resources for Vibration & haptics" into tm-dev am: 9c8d1e94fb am: c09c49fcf2

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/17914337

Change-Id: I4a46a73c2901720829056efa3c5d70ad89fb1114
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Lais Andrade
2022-04-28 00:15:40 +00:00
committed by Automerger Merge Worker
3 changed files with 11 additions and 4 deletions

View File

@@ -44,6 +44,9 @@ public class VibrationPreferenceController extends BasePreferenceController {
public CharSequence getSummary() {
final boolean isVibrateOn = Settings.System.getInt(mContext.getContentResolver(),
Settings.System.VIBRATE_ON, ON) == ON;
return mContext.getText(isVibrateOn ? R.string.switch_on_text : R.string.switch_off_text);
return mContext.getText(
isVibrateOn
? R.string.accessibility_vibration_settings_state_on
: R.string.accessibility_vibration_settings_state_off);
}
}