summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/CellLayout.java
diff options
context:
space:
mode:
authorJon Miranda <jonmiranda@google.com>2017-06-22 18:34:45 -0700
committerJon Miranda <jonmiranda@google.com>2017-06-22 18:34:45 -0700
commita0233f72bedd7d91cf2b6febec49fadf89a60c1f (patch)
treea60f824a2bbe83e34068fbb55d5963b9d721384d /src/com/android/launcher3/CellLayout.java
parent12461a16c9afed84418d2863bdf00ea512fbeab7 (diff)
downloadpackages_apps_Trebuchet-a0233f72bedd7d91cf2b6febec49fadf89a60c1f.tar.gz
packages_apps_Trebuchet-a0233f72bedd7d91cf2b6febec49fadf89a60c1f.tar.bz2
packages_apps_Trebuchet-a0233f72bedd7d91cf2b6febec49fadf89a60c1f.zip
Move PreviewBackground into its own class file.
This is done in preparation for new PreviewBackground animation where we will be animating in the first page preview items when closing the Folder from a non-first page. Bug: 36022592 Bug: 35064148 Change-Id: Id4d54da16ddfa852ca639a2dc8d328307d4d443a
Diffstat (limited to 'src/com/android/launcher3/CellLayout.java')
-rw-r--r--src/com/android/launcher3/CellLayout.java13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/com/android/launcher3/CellLayout.java b/src/com/android/launcher3/CellLayout.java
index d0d33a03d..d07e3303d 100644
--- a/src/com/android/launcher3/CellLayout.java
+++ b/src/com/android/launcher3/CellLayout.java
@@ -53,6 +53,7 @@ import com.android.launcher3.accessibility.WorkspaceAccessibilityHelper;
import com.android.launcher3.anim.PropertyListBuilder;
import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.folder.FolderIcon;
+import com.android.launcher3.folder.PreviewBackground;
import com.android.launcher3.graphics.DragPreviewProvider;
import com.android.launcher3.util.CellAndSpan;
import com.android.launcher3.util.GridOccupancy;
@@ -102,8 +103,8 @@ public class CellLayout extends ViewGroup implements BubbleTextShadowHandler {
private OnTouchListener mInterceptTouchListener;
private final StylusEventHelper mStylusEventHelper;
- private final ArrayList<FolderIcon.PreviewBackground> mFolderBackgrounds = new ArrayList<>();
- final FolderIcon.PreviewBackground mFolderLeaveBehind = new FolderIcon.PreviewBackground();
+ private final ArrayList<PreviewBackground> mFolderBackgrounds = new ArrayList<>();
+ final PreviewBackground mFolderLeaveBehind = new PreviewBackground();
private float mBackgroundAlpha;
@@ -495,7 +496,7 @@ public class CellLayout extends ViewGroup implements BubbleTextShadowHandler {
}
for (int i = 0; i < mFolderBackgrounds.size(); i++) {
- FolderIcon.PreviewBackground bg = mFolderBackgrounds.get(i);
+ PreviewBackground bg = mFolderBackgrounds.get(i);
cellToPoint(bg.delegateCellX, bg.delegateCellY, mTempLocation);
canvas.save();
canvas.translate(mTempLocation[0], mTempLocation[1]);
@@ -521,7 +522,7 @@ public class CellLayout extends ViewGroup implements BubbleTextShadowHandler {
super.dispatchDraw(canvas);
for (int i = 0; i < mFolderBackgrounds.size(); i++) {
- FolderIcon.PreviewBackground bg = mFolderBackgrounds.get(i);
+ PreviewBackground bg = mFolderBackgrounds.get(i);
if (bg.isClipping) {
cellToPoint(bg.delegateCellX, bg.delegateCellY, mTempLocation);
canvas.save();
@@ -532,10 +533,10 @@ public class CellLayout extends ViewGroup implements BubbleTextShadowHandler {
}
}
- public void addFolderBackground(FolderIcon.PreviewBackground bg) {
+ public void addFolderBackground(PreviewBackground bg) {
mFolderBackgrounds.add(bg);
}
- public void removeFolderBackground(FolderIcon.PreviewBackground bg) {
+ public void removeFolderBackground(PreviewBackground bg) {
mFolderBackgrounds.remove(bg);
}