diff --git a/core/java/com/android/internal/util/ContrastColorUtil.java b/core/java/com/android/internal/util/ContrastColorUtil.java index a403c068c7c4b..e0ba317f5eaad 100644 --- a/core/java/com/android/internal/util/ContrastColorUtil.java +++ b/core/java/com/android/internal/util/ContrastColorUtil.java @@ -586,7 +586,7 @@ public class ContrastColorUtil { * * @param color the base color to use * @param amount the amount from 1 to 100 how much to modify the color - * @return the now color that was modified + * @return the new color that was modified */ public static int getShiftedColor(int color, int amount) { final double[] result = ColorUtilsFromCompat.getTempDouble3Array(); @@ -599,6 +599,19 @@ public class ContrastColorUtil { return ColorUtilsFromCompat.LABToColor(result[0], result[1], result[2]); } + /** + * Blends the provided color with white to create a muted version. + * + * @param color the color to mute + * @param alpha the amount from 0 to 1 to set the alpha component of the white scrim + * @return the new color that was modified + */ + public static int getMutedColor(int color, float alpha) { + int whiteScrim = ColorUtilsFromCompat.setAlphaComponent( + Color.WHITE, (int) (255 * alpha)); + return compositeColors(whiteScrim, color); + } + private static boolean shouldUseDark(int backgroundColor, boolean defaultBackgroundIsDark) { if (backgroundColor == Notification.COLOR_DEFAULT) { return !defaultBackgroundIsDark; @@ -674,6 +687,18 @@ public class ContrastColorUtil { return ((0xFF * fgC * fgA) + (bgC * bgA * (0xFF - fgA))) / (a * 0xFF); } + /** + * Set the alpha component of {@code color} to be {@code alpha}. + */ + @ColorInt + public static int setAlphaComponent(@ColorInt int color, + @IntRange(from = 0x0, to = 0xFF) int alpha) { + if (alpha < 0 || alpha > 255) { + throw new IllegalArgumentException("alpha must be between 0 and 255."); + } + return (color & 0x00ffffff) | (alpha << 24); + } + /** * Returns the luminance of a color as a float between {@code 0.0} and {@code 1.0}. *
Defined as the Y component in the XYZ representation of {@code color}.
diff --git a/packages/SystemUI/res/layout/bubble_view.xml b/packages/SystemUI/res/layout/bubble_view.xml new file mode 100644 index 0000000000000..204408cda81fc --- /dev/null +++ b/packages/SystemUI/res/layout/bubble_view.xml @@ -0,0 +1,38 @@ + + ++ * If a notification has been set to bubble via proper bubble APIs or if it is an important + * message-like notification. + *
*/ private boolean shouldAutoBubble(Context context, NotificationEntry entry) { if (entry.isBubbleDismissed()) { diff --git a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedViewContainer.java b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedViewContainer.java index badefe182bdde..71ae1f8620f60 100644 --- a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedViewContainer.java +++ b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedViewContainer.java @@ -21,6 +21,7 @@ import android.content.Context; import android.content.res.Resources; import android.graphics.Color; import android.graphics.drawable.ShapeDrawable; +import android.text.TextUtils; import android.util.AttributeSet; import android.view.View; import android.widget.LinearLayout; @@ -88,6 +89,7 @@ public class BubbleExpandedViewContainer extends LinearLayout { */ public void setHeaderText(CharSequence text) { mHeaderView.setText(text); + mHeaderView.setVisibility(TextUtils.isEmpty(text) ? GONE : VISIBLE); } /** diff --git a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java index 3280a331a5c7b..1539584d82b3e 100644 --- a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java +++ b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java @@ -64,9 +64,9 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F private boolean mIsExpanded; private int mExpandedBubbleHeight; + private BubbleTouchHandler mTouchHandler; private BubbleView mExpandedBubble; private Point mCollapsedPosition; - private BubbleTouchHandler mTouchHandler; private BubbleController.BubbleExpandListener mExpandListener; private boolean mViewUpdatedRequested = false; @@ -211,13 +211,24 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F */ public void setExpandedBubble(BubbleView bubbleToExpand) { mExpandedBubble = bubbleToExpand; + boolean prevExpanded = mIsExpanded; mIsExpanded = true; - updateExpandedBubble(); - requestUpdate(); + if (!prevExpanded) { + // If we weren't previously expanded we should animate open. + animateExpansion(true /* expand */); + } else { + // If we were expanded just update the views + updateExpandedBubble(); + requestUpdate(); + } + mExpandedBubble.getEntry().setShowInShadeWhenBubble(false); + notifyExpansionChanged(mExpandedBubble, true /* expanded */); } /** - * Adds a bubble to the stack. + * Adds a bubble to the top of the stack. + * + * @param bubbleView the view to add to the stack. */ public void addBubble(BubbleView bubbleView) { mBubbleContainer.addView(bubbleView, 0, @@ -234,17 +245,26 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F mBubbleContainer.removeView(bubbleView); boolean wasExpanded = mIsExpanded; int bubbleCount = mBubbleContainer.getChildCount(); - if (bubbleView.equals(mExpandedBubble) && bubbleCount > 0) { + if (mIsExpanded && bubbleView.equals(mExpandedBubble) && bubbleCount > 0) { // If we have other bubbles and are expanded go to the next one or previous // if the bubble removed was last int nextIndex = bubbleCount > removedIndex ? removedIndex : bubbleCount - 1; - mExpandedBubble = (BubbleView) mBubbleContainer.getChildAt(nextIndex); + BubbleView expandedBubble = (BubbleView) mBubbleContainer.getChildAt(nextIndex); + setExpandedBubble(expandedBubble); } mIsExpanded = wasExpanded && mBubbleContainer.getChildCount() > 0; - requestUpdate(); - if (wasExpanded && !mIsExpanded && mExpandListener != null) { - mExpandListener.onBubbleExpandChanged(mIsExpanded, 1 /* amount */); + if (wasExpanded != mIsExpanded) { + notifyExpansionChanged(mExpandedBubble, mIsExpanded); } + requestUpdate(); + } + + /** + * Dismiss the stack of bubbles. + */ + public void stackDismissed() { + collapseStack(); + mBubbleContainer.removeAllViews(); } /** @@ -252,11 +272,19 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F * * @param bubbleView the view to update in the stack. * @param entry the entry to update it with. + * @param updatePosition whether this bubble should be moved to top of the stack. */ - public void updateBubble(BubbleView bubbleView, NotificationEntry entry) { - // TODO - move to top of bubble stack, make it show its update if it makes sense + public void updateBubble(BubbleView bubbleView, NotificationEntry entry, + boolean updatePosition) { bubbleView.update(entry); - if (bubbleView.equals(mExpandedBubble)) { + if (updatePosition && !mIsExpanded) { + // If alerting it gets promoted to top of the stack + mBubbleContainer.removeView(bubbleView); + mBubbleContainer.addView(bubbleView, 0); + requestUpdate(); + } + if (mIsExpanded && bubbleView.equals(mExpandedBubble)) { + entry.setShowInShadeWhenBubble(false); requestUpdate(); } } @@ -286,18 +314,37 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F return this; } + /** + * Collapses the stack of bubbles. + */ + public void collapseStack() { + if (mIsExpanded) { + // TODO: Save opened bubble & move it to top of stack + animateExpansion(false /* shouldExpand */); + notifyExpansionChanged(mExpandedBubble, mIsExpanded); + } + } + + /** + * Expands the stack fo bubbles. + */ + public void expandStack() { + if (!mIsExpanded) { + mExpandedBubble = getTopBubble(); + mExpandedBubble.getEntry().setShowInShadeWhenBubble(false); + animateExpansion(true /* shouldExpand */); + notifyExpansionChanged(mExpandedBubble, true /* expanded */); + } + } + /** * Tell the stack to animate to collapsed or expanded state. */ - public void animateExpansion(boolean shouldExpand) { + private void animateExpansion(boolean shouldExpand) { if (mIsExpanded != shouldExpand) { mIsExpanded = shouldExpand; - mExpandedBubble = shouldExpand ? getTopBubble() : null; updateExpandedBubble(); - if (mExpandListener != null) { - mExpandListener.onBubbleExpandChanged(mIsExpanded, 1 /* amount */); - } if (shouldExpand) { // Save current position so that we might return there savePosition(); @@ -347,6 +394,13 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F mCollapsedPosition = getPosition(); } + private void notifyExpansionChanged(BubbleView bubbleView, boolean expanded) { + if (mExpandListener != null) { + NotificationEntry entry = bubbleView != null ? bubbleView.getEntry() : null; + mExpandListener.onBubbleExpandChanged(expanded, entry != null ? entry.key : null); + } + } + private BubbleView getTopBubble() { return getBubbleAt(0); } @@ -400,6 +454,7 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F } if (mExpandedBubble.hasAppOverlayIntent()) { + // Bubble with activity view expanded state ActivityView expandedView = mExpandedBubble.getActivityView(); expandedView.setLayoutParams(new ViewGroup.LayoutParams( ViewGroup.LayoutParams.MATCH_PARENT, mExpandedBubbleHeight)); @@ -423,13 +478,20 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F } }); } else { + // Bubble with notification view expanded state ExpandableNotificationRow row = mExpandedBubble.getRowView(); - if (!row.equals(mExpandedViewContainer.getExpandedView())) { - // Different expanded view than what we have + if (row.getParent() != null) { + // Row might still be in the shade when we expand + ((ViewGroup) row.getParent()).removeView(row); + } + if (mIsExpanded) { + mExpandedViewContainer.setExpandedView(row); + } else { mExpandedViewContainer.setExpandedView(null); } - mExpandedViewContainer.setExpandedView(row); + // Bubble with notification as expanded state doesn't need a header / title mExpandedViewContainer.setHeaderText(null); + } int pointerPosition = mExpandedBubble.getPosition().x + (mExpandedBubble.getWidth() / 2); @@ -456,7 +518,8 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F int bubbsCount = mBubbleContainer.getChildCount(); for (int i = 0; i < bubbsCount; i++) { BubbleView bv = (BubbleView) mBubbleContainer.getChildAt(i); - bv.setZ(bubbsCount - 1); + bv.updateDotVisibility(); + bv.setZ(bubbsCount - i); int transX = mIsExpanded ? (bv.getWidth() + mBubblePadding) * i : mBubblePadding * i; ViewState viewState = new ViewState(); @@ -510,6 +573,7 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F private void applyRowState(ExpandableNotificationRow view) { view.reset(); view.setHeadsUp(false); + view.resetTranslation(); view.setOnKeyguard(false); view.setOnAmbient(false); view.setClipBottomAmount(0); diff --git a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleTouchHandler.java b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleTouchHandler.java index 96b2dbab9bdfb..97784b0f4f936 100644 --- a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleTouchHandler.java +++ b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleTouchHandler.java @@ -110,7 +110,7 @@ class BubbleTouchHandler implements View.OnTouchListener { : stack.getTargetView(event); boolean isFloating = targetView instanceof FloatingView; if (!isFloating || targetView == null || action == MotionEvent.ACTION_OUTSIDE) { - stack.animateExpansion(false /* shouldExpand */); + stack.collapseStack(); cleanUpDismissTarget(); resetTouches(); return false; @@ -196,9 +196,13 @@ class BubbleTouchHandler implements View.OnTouchListener { mMovementHelper.getTranslateAnim(floatingView, toGoTo, 100, 0).start(); } } else if (floatingView.equals(stack.getExpandedBubble())) { - stack.animateExpansion(false /* shouldExpand */); + stack.collapseStack(); } else if (isBubbleStack) { - stack.animateExpansion(!stack.isExpanded() /* shouldExpand */); + if (stack.isExpanded()) { + stack.collapseStack(); + } else { + stack.expandStack(); + } } else { stack.setExpandedBubble((BubbleView) floatingView); } diff --git a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java index c1bbb9379e9c5..91893ef3db005 100644 --- a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java +++ b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2012 The Android Open Source Project + * Copyright (C) 2018 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -16,40 +16,47 @@ package com.android.systemui.bubbles; +import android.annotation.Nullable; import android.app.ActivityView; import android.app.Notification; import android.app.PendingIntent; import android.content.Context; import android.graphics.Color; import android.graphics.Point; +import android.graphics.drawable.ColorDrawable; import android.graphics.drawable.Drawable; import android.graphics.drawable.Icon; -import android.graphics.drawable.ShapeDrawable; -import android.graphics.drawable.shapes.OvalShape; +import android.graphics.drawable.InsetDrawable; +import android.graphics.drawable.LayerDrawable; import android.util.AttributeSet; import android.util.Log; import android.view.View; import android.view.ViewGroup; -import android.widget.ImageView; -import android.widget.LinearLayout; +import android.widget.FrameLayout; +import android.widget.TextView; -import com.android.internal.util.ContrastColorUtil; +import com.android.internal.graphics.ColorUtils; +import com.android.systemui.Interpolators; import com.android.systemui.R; import com.android.systemui.statusbar.notification.collection.NotificationEntry; import com.android.systemui.statusbar.notification.row.ExpandableNotificationRow; /** - * A floating object on the screen that has a collapsed and expanded state. + * A floating object on the screen that can post message updates. */ -class BubbleView extends LinearLayout implements BubbleTouchHandler.FloatingView { +public class BubbleView extends FrameLayout implements BubbleTouchHandler.FloatingView { private static final String TAG = "BubbleView"; + // Same value as Launcher3 badge code + private static final float WHITE_SCRIM_ALPHA = 0.54f; private Context mContext; - private View mIconView; + + private BadgedImageView mBadgedImageView; + private TextView mMessageView; + private int mPadding; + private int mIconInset; private NotificationEntry mEntry; - private int mBubbleSize; - private int mIconSize; private PendingIntent mAppOverlayIntent; private ActivityView mActivityView; @@ -67,66 +74,156 @@ class BubbleView extends LinearLayout implements BubbleTouchHandler.FloatingView public BubbleView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) { super(context, attrs, defStyleAttr, defStyleRes); - setOrientation(LinearLayout.VERTICAL); mContext = context; - mBubbleSize = getResources().getDimensionPixelSize(R.dimen.bubble_size); - mIconSize = getResources().getDimensionPixelSize(R.dimen.bubble_icon_size); + // XXX: can this padding just be on the view and we look it up? + mPadding = getResources().getDimensionPixelSize(R.dimen.bubble_view_padding); + mIconInset = getResources().getDimensionPixelSize(R.dimen.bubble_icon_inset); + } + + @Override + protected void onFinishInflate() { + super.onFinishInflate(); + mBadgedImageView = (BadgedImageView) findViewById(R.id.bubble_image); + mMessageView = (TextView) findViewById(R.id.message_view); + mMessageView.setVisibility(GONE); + mMessageView.setPivotX(0); + } + + @Override + protected void onAttachedToWindow() { + super.onAttachedToWindow(); + updateViews(); + } + + @Override + protected void onMeasure(int widthSpec, int heightSpec) { + measureChild(mBadgedImageView, widthSpec, heightSpec); + measureChild(mMessageView, widthSpec, heightSpec); + boolean messageGone = mMessageView.getVisibility() == GONE; + int imageHeight = mBadgedImageView.getMeasuredHeight(); + int imageWidth = mBadgedImageView.getMeasuredWidth(); + int messageHeight = messageGone ? 0 : mMessageView.getMeasuredHeight(); + int messageWidth = messageGone ? 0 : mMessageView.getMeasuredWidth(); + setMeasuredDimension( + getPaddingStart() + imageWidth + mPadding + messageWidth + getPaddingEnd(), + getPaddingTop() + Math.max(imageHeight, messageHeight) + getPaddingBottom()); + } + + @Override + protected void onLayout(boolean changed, int left, int top, int right, int bottom) { + left = getPaddingStart(); + top = getPaddingTop(); + int imageWidth = mBadgedImageView.getMeasuredWidth(); + int imageHeight = mBadgedImageView.getMeasuredHeight(); + int messageWidth = mMessageView.getMeasuredWidth(); + int messageHeight = mMessageView.getMeasuredHeight(); + mBadgedImageView.layout(left, top, left + imageWidth, top + imageHeight); + mMessageView.layout(left + imageWidth + mPadding, top, + left + imageWidth + mPadding + messageWidth, top + messageHeight); } /** * Populates this view with a notification. + *
+ * This should only be called when a new notification is being set on the view, updates to the
+ * current notification should use {@link #update(NotificationEntry)}.
*
* @param entry the notification to display as a bubble.
*/
public void setNotif(NotificationEntry entry) {
- removeAllViews();
- // TODO: migrate to inflater
- mIconView = new ImageView(mContext);
- addView(mIconView);
-
- LinearLayout.LayoutParams iconLp = (LinearLayout.LayoutParams) mIconView.getLayoutParams();
- iconLp.width = mBubbleSize;
- iconLp.height = mBubbleSize;
- mIconView.setLayoutParams(iconLp);
-
- update(entry);
- }
-
- /**
- * Updates the UI based on the entry.
- */
- public void update(NotificationEntry entry) {
mEntry = entry;
- Notification n = entry.notification.getNotification();
- Icon ic = n.getLargeIcon() != null ? n.getLargeIcon() : n.getSmallIcon();
-
- if (n.getLargeIcon() == null) {
- createCircledIcon(n.color, ic, ((ImageView) mIconView));
- } else {
- ((ImageView) mIconView).setImageIcon(ic);
- }
+ updateViews();
}
/**
- * @return the key identifying this bubble / notification entry associated with this
- * bubble, if it exists.
- */
- public String getKey() {
- return mEntry == null ? null : mEntry.key;
- }
-
- /**
- * @return the notification entry associated with this bubble.
+ * The {@link NotificationEntry} associated with this view, if one exists.
*/
+ @Nullable
public NotificationEntry getEntry() {
return mEntry;
}
/**
- * @return the view to display notification content when the bubble is expanded.
+ * The key for the {@link NotificationEntry} associated with this view, if one exists.
*/
+ @Nullable
+ public String getKey() {
+ return (mEntry != null) ? mEntry.key : null;
+ }
+
+ /**
+ * Updates the UI based on the entry, updates badge and animates messages as needed.
+ */
+ public void update(NotificationEntry entry) {
+ mEntry = entry;
+ updateViews();
+ }
+
+
+ /**
+ * @return the {@link ExpandableNotificationRow} view to display notification content when the
+ * bubble is expanded.
+ */
+ @Nullable
public ExpandableNotificationRow getRowView() {
- return mEntry.getRow();
+ return (mEntry != null) ? mEntry.getRow() : null;
+ }
+
+ /**
+ * Marks this bubble as "read", i.e. no badge should show.
+ */
+ public void updateDotVisibility() {
+ boolean showDot = getEntry().showInShadeWhenBubble();
+ animateDot(showDot);
+ }
+
+ /**
+ * Animates the badge to show or hide.
+ */
+ private void animateDot(boolean showDot) {
+ if (mBadgedImageView.isShowingDot() != showDot) {
+ mBadgedImageView.setShowDot(showDot);
+ mBadgedImageView.clearAnimation();
+ mBadgedImageView.animate().setDuration(200)
+ .setInterpolator(Interpolators.FAST_OUT_SLOW_IN)
+ .setUpdateListener((valueAnimator) -> {
+ float fraction = valueAnimator.getAnimatedFraction();
+ fraction = showDot ? fraction : 1 - fraction;
+ mBadgedImageView.setDotScale(fraction);
+ }).withEndAction(() -> {
+ if (!showDot) {
+ mBadgedImageView.setShowDot(false);
+ }
+ }).start();
+ }
+ }
+
+ private void updateViews() {
+ if (mEntry == null) {
+ return;
+ }
+ Notification n = mEntry.notification.getNotification();
+ boolean isLarge = n.getLargeIcon() != null;
+ Icon ic = isLarge ? n.getLargeIcon() : n.getSmallIcon();
+ Drawable iconDrawable = ic.loadDrawable(mContext);
+ if (!isLarge) {
+ // Center icon on coloured background
+ iconDrawable.setTint(Color.WHITE); // TODO: dark mode
+ Drawable bg = new ColorDrawable(n.color);
+ InsetDrawable d = new InsetDrawable(iconDrawable, mIconInset);
+ Drawable[] layers = {bg, d};
+ mBadgedImageView.setImageDrawable(new LayerDrawable(layers));
+ } else {
+ mBadgedImageView.setImageDrawable(iconDrawable);
+ }
+ int badgeColor = determineDominateColor(iconDrawable, n.color);
+ mBadgedImageView.setDotColor(badgeColor);
+ animateDot(mEntry.showInShadeWhenBubble() /* showDot */);
+ }
+
+ private int determineDominateColor(Drawable d, int defaultTint) {
+ // XXX: should we pull from the drawable, app icon, notif tint?
+ return ColorUtils.blendARGB(defaultTint, Color.WHITE, WHITE_SCRIM_ALPHA);
}
/**
@@ -170,8 +267,8 @@ class BubbleView extends LinearLayout implements BubbleTouchHandler.FloatingView
@Override
public void setPosition(int x, int y) {
- setTranslationX(x);
- setTranslationY(y);
+ setPositionX(x);
+ setPositionY(y);
}
@Override
@@ -189,25 +286,6 @@ class BubbleView extends LinearLayout implements BubbleTouchHandler.FloatingView
return new Point((int) getTranslationX(), (int) getTranslationY());
}
- // Seems sub optimal
- private void createCircledIcon(int tint, Icon icon, ImageView v) {
- // TODO: dark mode
- icon.setTint(Color.WHITE);
- icon.scaleDownIfNecessary(mIconSize, mIconSize);
- v.setImageDrawable(icon.loadDrawable(mContext));
- v.setScaleType(ImageView.ScaleType.CENTER_INSIDE);
- LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) v.getLayoutParams();
- int color = ContrastColorUtil.ensureContrast(tint, Color.WHITE,
- false /* isBgDarker */, 3);
- Drawable d = new ShapeDrawable(new OvalShape());
- d.setTint(color);
- v.setBackgroundDrawable(d);
-
- lp.width = mBubbleSize;
- lp.height = mBubbleSize;
- v.setLayoutParams(lp);
- }
-
/**
* @return whether an ActivityView should be used to display the content of this Bubble
*/
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationViewHierarchyManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationViewHierarchyManager.java
index bf6caa010e9b1..f2ff85bb226ce 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationViewHierarchyManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationViewHierarchyManager.java
@@ -16,8 +16,6 @@
package com.android.systemui.statusbar;
-import static com.android.systemui.statusbar.StatusBarState.SHADE;
-
import android.content.Context;
import android.content.res.Resources;
import android.os.Trace;
@@ -26,7 +24,6 @@ import android.view.View;
import android.view.ViewGroup;
import com.android.systemui.R;
-import com.android.systemui.bubbles.BubbleController;
import com.android.systemui.statusbar.notification.NotificationEntryManager;
import com.android.systemui.statusbar.notification.VisualStabilityManager;
import com.android.systemui.statusbar.notification.collection.NotificationEntry;
@@ -66,7 +63,6 @@ public class NotificationViewHierarchyManager {
protected final VisualStabilityManager mVisualStabilityManager;
private final StatusBarStateController mStatusBarStateController;
private final NotificationEntryManager mEntryManager;
- private final BubbleController mBubbleController;
// Lazy
private final Lazy When a notification is a bubble we don't show it in the shade once the bubble has been
+ * expanded