Minor change for CaptionAppearanceFragment

1. Move unnecessary public variables into local variables
2. Use %s to update locale preference summary
3. Correct the test case name of CaptionPreviewPreferenceControllerTest

Bug: 197695932
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.accessibility
Change-Id: I58d4d590b9b6d46c27d389217f846a780d755891
This commit is contained in:
menghanli
2022-07-29 08:26:44 +08:00
parent 6544dee983
commit b9194c4eb8
10 changed files with 54 additions and 56 deletions

View File

@@ -188,17 +188,27 @@ public class CaptionHelper {
}
/**
* Sets the caption raw user style.
* Sets the captioning raw user style.
*
* @param type The caption raw user style
* @param type The captioning raw user style
*/
public void setRawUserStyle(int type) {
Settings.Secure.putInt(mContentResolver,
Settings.Secure.ACCESSIBILITY_CAPTIONING_PRESET, type);
}
/** Returns the caption raw user style.*/
/** Returns the captioning raw preset number.*/
public int getRawUserStyle() {
return mCaptioningManager.getRawUserStyle();
}
/** Returns the captioning visual properties.*/
public CaptionStyle getUserStyle() {
return mCaptioningManager.getUserStyle();
}
/** Returns the captioning locale language.*/
public Locale getLocale() {
return mCaptioningManager.getLocale();
}
}