Revert "Add ability to show/hide Color Correction and Color Inversion."
This reverts commit f1346930bc
.
Reason for revert: Moving logic elsewhere.
Change-Id: Ia07b3f4c33e0078e8f35c69d5ed51daf197ff165
This commit is contained in:
@@ -92,6 +92,8 @@ public class AccessibilitySettings extends SettingsPreferenceFragment implements
|
||||
// Preferences
|
||||
private static final String TOGGLE_HIGH_TEXT_CONTRAST_PREFERENCE =
|
||||
"toggle_high_text_contrast_preference";
|
||||
private static final String TOGGLE_INVERSION_PREFERENCE =
|
||||
"toggle_inversion_preference";
|
||||
private static final String TOGGLE_POWER_BUTTON_ENDS_CALL_PREFERENCE =
|
||||
"toggle_power_button_ends_call_preference";
|
||||
private static final String TOGGLE_LOCK_SCREEN_ROTATION_PREFERENCE =
|
||||
@@ -117,10 +119,7 @@ public class AccessibilitySettings extends SettingsPreferenceFragment implements
|
||||
"autoclick_preference_screen";
|
||||
private static final String VIBRATION_PREFERENCE_SCREEN =
|
||||
"vibration_preference_screen";
|
||||
|
||||
@VisibleForTesting static final String TOGGLE_INVERSION_PREFERENCE =
|
||||
"toggle_inversion_preference";
|
||||
@VisibleForTesting static final String DISPLAY_DALTONIZER_PREFERENCE_SCREEN =
|
||||
private static final String DISPLAY_DALTONIZER_PREFERENCE_SCREEN =
|
||||
"daltonizer_preference_screen";
|
||||
|
||||
// Extras passed to sub-fragments.
|
||||
@@ -626,8 +625,6 @@ public class AccessibilitySettings extends SettingsPreferenceFragment implements
|
||||
displayCategory.addPreference(mToggleInversionPreference);
|
||||
displayCategory.addPreference(mDisplayDaltonizerPreferenceScreen);
|
||||
}
|
||||
checkColorCorrectionVisibility(mDisplayDaltonizerPreferenceScreen);
|
||||
checkColorInversionVisibility(mToggleInversionPreference);
|
||||
|
||||
// Text contrast.
|
||||
mToggleHighTextContrastPreference.setChecked(
|
||||
@@ -802,20 +799,6 @@ public class AccessibilitySettings extends SettingsPreferenceFragment implements
|
||||
}
|
||||
}
|
||||
|
||||
@VisibleForTesting void checkColorCorrectionVisibility(Preference preference) {
|
||||
if (!getContext().getResources().getBoolean(
|
||||
R.bool.config_show_color_correction_preference)) {
|
||||
removePreference(DISPLAY_DALTONIZER_PREFERENCE_SCREEN);
|
||||
}
|
||||
}
|
||||
|
||||
@VisibleForTesting void checkColorInversionVisibility(Preference preference) {
|
||||
if (!getContext().getResources().getBoolean(
|
||||
R.bool.config_show_color_inversion_preference)) {
|
||||
removePreference(TOGGLE_INVERSION_PREFERENCE);
|
||||
}
|
||||
}
|
||||
|
||||
private static void configureMagnificationPreferenceIfNeeded(Preference preference) {
|
||||
// Some devices support only a single magnification mode. In these cases, we redirect to
|
||||
// the magnification mode's UI directly, rather than showing a PreferenceScreen with a
|
||||
|
Reference in New Issue
Block a user