Merge "Fix marquee animating in QuickSettings when invisible to user." into qt-dev

am: c70d1dc2a5

Change-Id: I3cd67272c5946fedd9cd9a11696488d9bf40b23d
This commit is contained in:
Aran Ink
2019-05-31 13:23:36 -07:00
committed by android-build-merger
3 changed files with 11 additions and 0 deletions

View File

@@ -21,6 +21,7 @@
android:layout_below="@id/quick_status_bar_system_icons"
android:paddingStart="@dimen/status_bar_padding_start"
android:paddingEnd="@dimen/status_bar_padding_end"
android:visibility="invisible"
android:theme="@style/QSHeaderTheme">
<com.android.systemui.qs.QSHeaderInfoLayout

View File

@@ -461,6 +461,11 @@ public class QuickStatusBarHeader extends RelativeLayout implements
if (mHeaderTextContainerAlphaAnimator != null) {
mHeaderTextContainerAlphaAnimator.setPosition(keyguardExpansionFraction);
if (keyguardExpansionFraction > 0) {
mHeaderTextContainerView.setVisibility(VISIBLE);
} else {
mHeaderTextContainerView.setVisibility(INVISIBLE);
}
}
if (mPrivacyChipAlphaAnimator != null) {
mPrivacyChip.setExpanded(expansionFraction > 0.5);

View File

@@ -48,6 +48,11 @@ public class AutoMarqueeTextView extends TextView {
super(context, attrs, defStyleAttr, defStyleRes);
}
@Override
protected void onFinishInflate() {
onVisibilityAggregated(isVisibleToUser());
}
@Override
protected void onAttachedToWindow() {
super.onAttachedToWindow();