Merge "Fix HDR blownout issue in the Photos app with HDR display on." into udc-dev am: 059a0275d4 am: 295fa31d11
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/23563190 Change-Id: I3c06b00ffd1c67e93d77f1e6f52b202fd555d777 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -5460,7 +5460,7 @@ public final class ViewRootImpl implements ViewParent,
|
||||
}
|
||||
|
||||
private void updateRenderHdrSdrRatio() {
|
||||
mRenderHdrSdrRatio = mDisplay.getHdrSdrRatio();
|
||||
mRenderHdrSdrRatio = Math.min(mDesiredHdrSdrRatio, mDisplay.getHdrSdrRatio());
|
||||
mUpdateHdrSdrRatioInfo = true;
|
||||
}
|
||||
|
||||
@@ -5488,22 +5488,14 @@ public final class ViewRootImpl implements ViewParent,
|
||||
mHdrSdrRatioChangedListener = null;
|
||||
} else {
|
||||
mHdrSdrRatioChangedListener = display -> {
|
||||
setTargetHdrSdrRatio(display.getHdrSdrRatio());
|
||||
updateRenderHdrSdrRatio();
|
||||
invalidate();
|
||||
};
|
||||
mDisplay.registerHdrSdrRatioChangedListener(mExecutor, mHdrSdrRatioChangedListener);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** happylint */
|
||||
public void setTargetHdrSdrRatio(float ratio) {
|
||||
if (mRenderHdrSdrRatio != ratio) {
|
||||
mRenderHdrSdrRatio = ratio;
|
||||
mUpdateHdrSdrRatioInfo = true;
|
||||
invalidate();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void requestChildFocus(View child, View focused) {
|
||||
if (DEBUG_INPUT_RESIZE) {
|
||||
|
||||
Reference in New Issue
Block a user