Merge "Fix overlapping alpha of shade pull down" into sc-v2-dev am: b223ed581c

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16144138

Change-Id: I36f8bcc5bc6d8760feb334c43543f217f6f3321e
This commit is contained in:
Lucas Dupin
2021-10-29 16:18:17 +00:00
committed by Automerger Merge Worker
2 changed files with 2 additions and 0 deletions

View File

@@ -106,6 +106,7 @@ class PlayerViewHolder private constructor(itemView: View) {
*/
@JvmStatic fun create(inflater: LayoutInflater, parent: ViewGroup): PlayerViewHolder {
val mediaView = inflater.inflate(R.layout.media_view, parent, false)
mediaView.setLayerType(View.LAYER_TYPE_HARDWARE, null)
// Because this media view (a TransitionLayout) is used to measure and layout the views
// in various states before being attached to its parent, we can't depend on the default
// LAYOUT_DIRECTION_INHERIT to correctly resolve the ltr direction.

View File

@@ -60,6 +60,7 @@ public class BrightnessSliderView extends FrameLayout {
@Override
protected void onFinishInflate() {
super.onFinishInflate();
setLayerType(LAYER_TYPE_HARDWARE, null);
mSlider = requireViewById(R.id.slider);
mSlider.setAccessibilityLabel(getContentDescription().toString());