diff options
author | Charlie Anderson <charlander@google.com> | 2023-03-14 13:18:56 -0400 |
---|---|---|
committer | Charlie Anderson <charlander@google.com> | 2023-03-23 20:57:49 +0000 |
commit | c93d6948e06566f03a82ae12e24571d990a9d885 (patch) | |
tree | 79a9b9b13b180c274f982711391362d2ee1d6091 /src/com/android/launcher3/popup | |
parent | 0607e6435e880897c2b769580a624219aca74356 (diff) | |
download | Launcher3-c93d6948e06566f03a82ae12e24571d990a9d885.tar.gz |
sets the initial arrow color for the popup to match the popup background.
Bug: 247880037
Test: tested popups manually on device
Change-Id: I6374e1a20aaeac1eb375108a91f0a49c088a15a9
Diffstat (limited to 'src/com/android/launcher3/popup')
-rw-r--r-- | src/com/android/launcher3/popup/ArrowPopup.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/com/android/launcher3/popup/ArrowPopup.java b/src/com/android/launcher3/popup/ArrowPopup.java index 9d06d4a6fa..0edf2921ae 100644 --- a/src/com/android/launcher3/popup/ArrowPopup.java +++ b/src/com/android/launcher3/popup/ArrowPopup.java @@ -140,13 +140,11 @@ public abstract class ArrowPopup<T extends Context & ActivityContext> mOutlineRadius = Themes.getDialogCornerRadius(context); mActivityContext = ActivityContext.lookupContext(context); mIsRtl = Utilities.isRtl(getResources()); - - int popupPrimaryColor = Themes.getAttrColor(context, R.attr.popupColorPrimary); - mArrowColor = popupPrimaryColor; mElevation = getResources().getDimension(R.dimen.deep_shortcuts_elevation); // Initialize arrow view final Resources resources = getResources(); + mArrowColor = getColorStateList(getContext(), R.color.popup_shade_first).getDefaultColor(); mMargin = resources.getDimensionPixelSize(R.dimen.popup_margin); mArrowWidth = resources.getDimensionPixelSize(R.dimen.popup_arrow_width); mArrowHeight = resources.getDimensionPixelSize(R.dimen.popup_arrow_height); @@ -159,6 +157,7 @@ public abstract class ArrowPopup<T extends Context & ActivityContext> int smallerRadius = resources.getDimensionPixelSize(R.dimen.popup_smaller_radius); mRoundedTop = new GradientDrawable(); + int popupPrimaryColor = Themes.getAttrColor(context, R.attr.popupColorPrimary); mRoundedTop.setColor(popupPrimaryColor); mRoundedTop.setCornerRadii(new float[] { mOutlineRadius, mOutlineRadius, mOutlineRadius, mOutlineRadius, smallerRadius, smallerRadius, smallerRadius, smallerRadius}); |