Merge "Fix transparent view initial height" into tm-qpr-dev am: 32e3767ec3 am: 4b04ea318b

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

Change-Id: I134eadff33bc35133afc83070729d7c39174875b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Anton Potapov
2022-11-14 18:42:45 +00:00
committed by Automerger Merge Worker

View File

@@ -82,12 +82,12 @@ public class QSCustomizer extends LinearLayout {
DefaultItemAnimator animator = new DefaultItemAnimator();
animator.setMoveDuration(TileAdapter.MOVE_DURATION);
mRecyclerView.setItemAnimator(animator);
updateTransparentViewHeight();
}
void updateResources() {
LayoutParams lp = (LayoutParams) mTransparentView.getLayoutParams();
lp.height = QSUtils.getQsHeaderSystemIconsAreaHeight(mContext);
mTransparentView.setLayoutParams(lp);
updateTransparentViewHeight();
mRecyclerView.getAdapter().notifyItemChanged(0);
}
@@ -236,4 +236,10 @@ public class QSCustomizer extends LinearLayout {
public boolean isOpening() {
return mOpening;
}
private void updateTransparentViewHeight() {
LayoutParams lp = (LayoutParams) mTransparentView.getLayoutParams();
lp.height = QSUtils.getQsHeaderSystemIconsAreaHeight(mContext);
mTransparentView.setLayoutParams(lp);
}
}