Merge "Check system support of wide-color"
This commit is contained in:
committed by
Android (Google) Code Review
commit
dd1a43ecab
@@ -545,7 +545,7 @@ public class DevelopmentSettings extends RestrictedSettingsFragment
|
|||||||
mColorModePreference = (ColorModePreference) findPreference(KEY_COLOR_MODE);
|
mColorModePreference = (ColorModePreference) findPreference(KEY_COLOR_MODE);
|
||||||
mColorModePreference.updateCurrentAndSupported();
|
mColorModePreference.updateCurrentAndSupported();
|
||||||
if (mColorModePreference.getColorModeCount() < 2 ||
|
if (mColorModePreference.getColorModeCount() < 2 ||
|
||||||
getContext().getDisplay().isWideColorGamut()) {
|
getContext().getResources().getConfiguration().isScreenWideColorGamut()) {
|
||||||
removePreference(KEY_COLOR_MODE);
|
removePreference(KEY_COLOR_MODE);
|
||||||
mColorModePreference = null;
|
mColorModePreference = null;
|
||||||
}
|
}
|
||||||
|
@@ -91,7 +91,7 @@ public class PictureColorModePreferenceController extends
|
|||||||
|
|
||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
boolean isWideColorGamut() {
|
boolean isWideColorGamut() {
|
||||||
return mContext.getDisplay().isWideColorGamut();
|
return mContext.getResources().getConfiguration().isScreenWideColorGamut();
|
||||||
}
|
}
|
||||||
|
|
||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
|
Reference in New Issue
Block a user