diff options
author | Sunny Goyal <sunnygoyal@google.com> | 2021-05-20 20:18:47 +0000 |
---|---|---|
committer | Sunny Goyal <sunnygoyal@google.com> | 2021-05-21 07:05:02 +0000 |
commit | d5500548dca15d4103d1d654fb1bf9fe8cf465a8 (patch) | |
tree | 639568e1c4bf2ad90b6ff44ae0a42598d5afe4b0 /quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java | |
parent | fd3ad5d769fb82705033069cf8e08249721f2faa (diff) |
Revert^2 "Moving taskbar lifecycle to TouchInteractionService"
430465a3d5ff0dcdd0c2e263d862049d93075a07
Bug: 187353581
Change-Id: I7b2280d16adfafd3e85ffc1d22e32d0c00d12b67
Diffstat (limited to 'quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java')
-rw-r--r-- | quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java index 5eb34cb360..ee44927ce4 100644 --- a/quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java +++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarDragController.java @@ -20,6 +20,7 @@ import static android.view.View.VISIBLE; import android.content.ClipData; import android.content.ClipDescription; +import android.content.Context; import android.content.Intent; import android.content.pm.LauncherApps; import android.content.res.Resources; @@ -29,7 +30,6 @@ import android.os.UserHandle; import android.view.DragEvent; import android.view.View; -import com.android.launcher3.BaseQuickstepLauncher; import com.android.launcher3.BubbleTextView; import com.android.launcher3.LauncherSettings; import com.android.launcher3.R; @@ -43,12 +43,12 @@ import com.android.systemui.shared.system.LauncherAppsCompat; */ public class TaskbarDragController { - private final BaseQuickstepLauncher mLauncher; + private final Context mContext; private final int mDragIconSize; - public TaskbarDragController(BaseQuickstepLauncher launcher) { - mLauncher = launcher; - Resources resources = mLauncher.getResources(); + public TaskbarDragController(Context context) { + mContext = context; + Resources resources = mContext.getResources(); mDragIconSize = resources.getDimensionPixelSize(R.dimen.taskbar_icon_drag_icon_size); } @@ -63,7 +63,6 @@ public class TaskbarDragController { } BubbleTextView btv = (BubbleTextView) view; - View.DragShadowBuilder shadowBuilder = new View.DragShadowBuilder(view) { @Override public void onProvideShadowMetrics(Point shadowSize, Point shadowTouchPoint) { @@ -87,7 +86,7 @@ public class TaskbarDragController { Intent intent = null; if (tag instanceof WorkspaceItemInfo) { WorkspaceItemInfo item = (WorkspaceItemInfo) tag; - LauncherApps launcherApps = mLauncher.getSystemService(LauncherApps.class); + LauncherApps launcherApps = mContext.getSystemService(LauncherApps.class); clipDescription = new ClipDescription(item.title, new String[] { item.itemType == LauncherSettings.Favorites.ITEM_TYPE_DEEP_SHORTCUT |