Loading quickstep/src/com/android/launcher3/taskbar/TaskbarView.java +7 −1 Original line number Diff line number Diff line Loading @@ -47,6 +47,7 @@ import com.android.launcher3.model.data.ItemInfo; import com.android.launcher3.model.data.WorkspaceItemInfo; import com.android.launcher3.util.DisplayController; import com.android.launcher3.util.LauncherBindableItemsContainer; import com.android.launcher3.util.Themes; import com.android.launcher3.views.ActivityContext; import com.android.launcher3.views.DoubleShadowBubbleTextView; import com.android.launcher3.views.IconButtonView; Loading @@ -66,6 +67,7 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar private final int mIconTouchSize; private final int mItemMarginLeftRight; private final int mItemPadding; private final int mFolderLeaveBehindColor; private final boolean mIsRtl; private final TaskbarActivityContext mActivityContext; Loading Loading @@ -132,6 +134,9 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar mItemMarginLeftRight = actualMargin - (mIconTouchSize - actualIconSize) / 2; mItemPadding = (mIconTouchSize - actualIconSize) / 2; mFolderLeaveBehindColor = Themes.getAttrColor(mActivityContext, android.R.attr.textColorTertiary); // Needed to draw folder leave-behind when opening one. setWillNotDraw(false); Loading Loading @@ -523,7 +528,8 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar if (mLeaveBehindFolderIcon != null) { canvas.save(); canvas.translate(mLeaveBehindFolderIcon.getLeft(), mLeaveBehindFolderIcon.getTop()); mLeaveBehindFolderIcon.getFolderBackground().drawLeaveBehind(canvas); mLeaveBehindFolderIcon.getFolderBackground().drawLeaveBehind(canvas, mFolderLeaveBehindColor); canvas.restore(); } } Loading src/com/android/launcher3/CellLayout.java +4 −1 Original line number Diff line number Diff line Loading @@ -92,6 +92,9 @@ public class CellLayout extends ViewGroup { private static final String TAG = "CellLayout"; private static final boolean LOGD = false; /** The color of the "leave-behind" shape when a folder is opened from Hotseat. */ private static final int FOLDER_LEAVE_BEHIND_COLOR = Color.argb(160, 245, 245, 245); protected final ActivityContext mActivity; @ViewDebug.ExportedProperty(category = "launcher") @Thunk int mCellWidth; Loading Loading @@ -528,7 +531,7 @@ public class CellLayout extends ViewGroup { mFolderLeaveBehind.mDelegateCellY, mTempLocation); canvas.save(); canvas.translate(mTempLocation[0], mTempLocation[1]); mFolderLeaveBehind.drawLeaveBehind(canvas); mFolderLeaveBehind.drawLeaveBehind(canvas, FOLDER_LEAVE_BEHIND_COLOR); canvas.restore(); } Loading src/com/android/launcher3/folder/PreviewBackground.java +5 −2 Original line number Diff line number Diff line Loading @@ -333,12 +333,15 @@ public class PreviewBackground extends CellLayout.DelegatedCellDrawing { getOffsetX() + inset, getOffsetY() + inset, getScaledRadius() - inset, mPaint); } public void drawLeaveBehind(Canvas canvas) { /** * Draws the leave-behind circle on the given canvas and in the given color. */ public void drawLeaveBehind(Canvas canvas, int color) { float originalScale = mScale; mScale = 0.5f; mPaint.setStyle(Paint.Style.FILL); mPaint.setColor(Color.argb(160, 245, 245, 245)); mPaint.setColor(color); getShape().drawShape(canvas, getOffsetX(), getOffsetY(), getScaledRadius(), mPaint); mScale = originalScale; Loading Loading
quickstep/src/com/android/launcher3/taskbar/TaskbarView.java +7 −1 Original line number Diff line number Diff line Loading @@ -47,6 +47,7 @@ import com.android.launcher3.model.data.ItemInfo; import com.android.launcher3.model.data.WorkspaceItemInfo; import com.android.launcher3.util.DisplayController; import com.android.launcher3.util.LauncherBindableItemsContainer; import com.android.launcher3.util.Themes; import com.android.launcher3.views.ActivityContext; import com.android.launcher3.views.DoubleShadowBubbleTextView; import com.android.launcher3.views.IconButtonView; Loading @@ -66,6 +67,7 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar private final int mIconTouchSize; private final int mItemMarginLeftRight; private final int mItemPadding; private final int mFolderLeaveBehindColor; private final boolean mIsRtl; private final TaskbarActivityContext mActivityContext; Loading Loading @@ -132,6 +134,9 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar mItemMarginLeftRight = actualMargin - (mIconTouchSize - actualIconSize) / 2; mItemPadding = (mIconTouchSize - actualIconSize) / 2; mFolderLeaveBehindColor = Themes.getAttrColor(mActivityContext, android.R.attr.textColorTertiary); // Needed to draw folder leave-behind when opening one. setWillNotDraw(false); Loading Loading @@ -523,7 +528,8 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar if (mLeaveBehindFolderIcon != null) { canvas.save(); canvas.translate(mLeaveBehindFolderIcon.getLeft(), mLeaveBehindFolderIcon.getTop()); mLeaveBehindFolderIcon.getFolderBackground().drawLeaveBehind(canvas); mLeaveBehindFolderIcon.getFolderBackground().drawLeaveBehind(canvas, mFolderLeaveBehindColor); canvas.restore(); } } Loading
src/com/android/launcher3/CellLayout.java +4 −1 Original line number Diff line number Diff line Loading @@ -92,6 +92,9 @@ public class CellLayout extends ViewGroup { private static final String TAG = "CellLayout"; private static final boolean LOGD = false; /** The color of the "leave-behind" shape when a folder is opened from Hotseat. */ private static final int FOLDER_LEAVE_BEHIND_COLOR = Color.argb(160, 245, 245, 245); protected final ActivityContext mActivity; @ViewDebug.ExportedProperty(category = "launcher") @Thunk int mCellWidth; Loading Loading @@ -528,7 +531,7 @@ public class CellLayout extends ViewGroup { mFolderLeaveBehind.mDelegateCellY, mTempLocation); canvas.save(); canvas.translate(mTempLocation[0], mTempLocation[1]); mFolderLeaveBehind.drawLeaveBehind(canvas); mFolderLeaveBehind.drawLeaveBehind(canvas, FOLDER_LEAVE_BEHIND_COLOR); canvas.restore(); } Loading
src/com/android/launcher3/folder/PreviewBackground.java +5 −2 Original line number Diff line number Diff line Loading @@ -333,12 +333,15 @@ public class PreviewBackground extends CellLayout.DelegatedCellDrawing { getOffsetX() + inset, getOffsetY() + inset, getScaledRadius() - inset, mPaint); } public void drawLeaveBehind(Canvas canvas) { /** * Draws the leave-behind circle on the given canvas and in the given color. */ public void drawLeaveBehind(Canvas canvas, int color) { float originalScale = mScale; mScale = 0.5f; mPaint.setStyle(Paint.Style.FILL); mPaint.setColor(Color.argb(160, 245, 245, 245)); mPaint.setColor(color); getShape().drawShape(canvas, getOffsetX(), getOffsetY(), getScaledRadius(), mPaint); mScale = originalScale; Loading