Loading libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarAnimationHelper.java +0 −1 Original line number Diff line number Diff line Loading @@ -298,7 +298,6 @@ public class BubbleBarAnimationHelper { final float endTx = toBbev.getTranslationX(); final float startTx = getSwitchAnimationInitialTx(endTx); toBbev.getHandleView().setAlpha(0f); toBbev.getHandleView().setHandleInitialColor(fromBbev.getHandleView().getHandleColor()); AnimatorSet switchAnim = new AnimatorSet(); switchAnim.playTogether( Loading libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarExpandedView.java +6 −2 Original line number Diff line number Diff line Loading @@ -394,9 +394,13 @@ public class BubbleBarExpandedView extends FrameLayout implements BubbleTaskView if (!isValidToBubble(taskInfo)) { Toast.makeText(mContext, R.string.bubble_not_supported_text, Toast.LENGTH_SHORT).show(); } else if (mCaptionView != null && taskInfo != null && taskInfo.taskDescription != null) { final int statusBarColor = taskInfo.taskDescription.getStatusBarColor(); final int bgColor = taskInfo.taskDescription.getBackgroundColor(); if (Color.alpha(bgColor) != 0) { // Set the caption's color to the color override of the task if not transparent. if (Color.alpha(statusBarColor) != 0) { // Set the caption's color to the color of the status bar if not transparent. mCaptionView.setBackgroundColor(statusBarColor); } else if (Color.alpha(bgColor) != 0) { // Otherwise, use the background color of the task if it's not transparent. mCaptionView.setBackgroundColor(bgColor); } } Loading libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarHandleView.java +0 −10 Original line number Diff line number Diff line Loading @@ -131,16 +131,6 @@ public class BubbleBarHandleView extends View { invalidate(); } /** * Set initial color for the handle. Takes effect if the * {@link #updateHandleColor(boolean, boolean)} has not been called. */ public void setHandleInitialColor(@ColorInt int color) { if (color != mHandleColor) { setHandleColor(color); } } /** * Updates the handle color. * Loading libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/bubbles/bar/BubbleBarHandleViewTest.java +0 −6 Original line number Diff line number Diff line Loading @@ -64,10 +64,4 @@ public class BubbleBarHandleViewTest extends ShellTestCase { assertEquals(handleColor, ContextCompat.getColor(mContext, R.color.bubble_bar_expanded_view_handle_light)); } @Test public void testSetHandleInitialColor_beforeUpdateHandleColor_updatesColor() { mHandleView.setHandleInitialColor(Color.RED); assertThat(mHandleView.getHandleColor()).isEqualTo(Color.RED); } } Loading
libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarAnimationHelper.java +0 −1 Original line number Diff line number Diff line Loading @@ -298,7 +298,6 @@ public class BubbleBarAnimationHelper { final float endTx = toBbev.getTranslationX(); final float startTx = getSwitchAnimationInitialTx(endTx); toBbev.getHandleView().setAlpha(0f); toBbev.getHandleView().setHandleInitialColor(fromBbev.getHandleView().getHandleColor()); AnimatorSet switchAnim = new AnimatorSet(); switchAnim.playTogether( Loading
libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarExpandedView.java +6 −2 Original line number Diff line number Diff line Loading @@ -394,9 +394,13 @@ public class BubbleBarExpandedView extends FrameLayout implements BubbleTaskView if (!isValidToBubble(taskInfo)) { Toast.makeText(mContext, R.string.bubble_not_supported_text, Toast.LENGTH_SHORT).show(); } else if (mCaptionView != null && taskInfo != null && taskInfo.taskDescription != null) { final int statusBarColor = taskInfo.taskDescription.getStatusBarColor(); final int bgColor = taskInfo.taskDescription.getBackgroundColor(); if (Color.alpha(bgColor) != 0) { // Set the caption's color to the color override of the task if not transparent. if (Color.alpha(statusBarColor) != 0) { // Set the caption's color to the color of the status bar if not transparent. mCaptionView.setBackgroundColor(statusBarColor); } else if (Color.alpha(bgColor) != 0) { // Otherwise, use the background color of the task if it's not transparent. mCaptionView.setBackgroundColor(bgColor); } } Loading
libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/bar/BubbleBarHandleView.java +0 −10 Original line number Diff line number Diff line Loading @@ -131,16 +131,6 @@ public class BubbleBarHandleView extends View { invalidate(); } /** * Set initial color for the handle. Takes effect if the * {@link #updateHandleColor(boolean, boolean)} has not been called. */ public void setHandleInitialColor(@ColorInt int color) { if (color != mHandleColor) { setHandleColor(color); } } /** * Updates the handle color. * Loading
libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/bubbles/bar/BubbleBarHandleViewTest.java +0 −6 Original line number Diff line number Diff line Loading @@ -64,10 +64,4 @@ public class BubbleBarHandleViewTest extends ShellTestCase { assertEquals(handleColor, ContextCompat.getColor(mContext, R.color.bubble_bar_expanded_view_handle_light)); } @Test public void testSetHandleInitialColor_beforeUpdateHandleColor_updatesColor() { mHandleView.setHandleInitialColor(Color.RED); assertThat(mHandleView.getHandleColor()).isEqualTo(Color.RED); } }