summaryrefslogtreecommitdiffstats
path: root/go/quickstep
diff options
context:
space:
mode:
authorHyunyoung Song <hyunyoungs@google.com>2019-11-20 00:32:39 -0800
committerHyunyoung Song <hyunyoungs@google.com>2019-11-20 08:40:59 +0000
commit793f5c518656f94732be695eac4d5b01fa50ae01 (patch)
treea1a981f65c0ac1744f46c2f05f7777419127a86e /go/quickstep
parent47835458089c656139246f13dbcd5baedfec3c16 (diff)
parent9353b00616ac688d2df6b9f8513c4895bb4119d7 (diff)
downloadandroid_packages_apps_Trebuchet-793f5c518656f94732be695eac4d5b01fa50ae01.tar.gz
android_packages_apps_Trebuchet-793f5c518656f94732be695eac4d5b01fa50ae01.tar.bz2
android_packages_apps_Trebuchet-793f5c518656f94732be695eac4d5b01fa50ae01.zip
Merging from ub-launcher3-qt-future-dev @ build 6018744
Test: manual, presubmit on the source branch http://x20/teams/android-launcher/merge/ub-launcher3-qt-future-dev_6018744.htmlMerge commit '9353b00616ac688d2df6b9f8513c4895bb4119d7' into merge_ub-launcher3-qt-future-dev_6018744 Change-Id: Ie6235a262b7bba0aa9f2a2962a7aa499a0a2cb53 Merged-In: I8a1e20d0b175f03a1a05c81749f07ab5314e872a
Diffstat (limited to 'go/quickstep')
-rw-r--r--go/quickstep/res/values/override.xml2
-rw-r--r--go/quickstep/src/com/android/quickstep/OverviewCommandHelper.java17
-rw-r--r--go/quickstep/src/com/android/quickstep/TouchInteractionService.java5
3 files changed, 9 insertions, 15 deletions
diff --git a/go/quickstep/res/values/override.xml b/go/quickstep/res/values/override.xml
index 7636fb30b..bb267a392 100644
--- a/go/quickstep/res/values/override.xml
+++ b/go/quickstep/res/values/override.xml
@@ -22,5 +22,7 @@
<string name="instant_app_resolver_class" translatable="false">com.android.quickstep.InstantAppResolverImpl</string>
<string name="main_process_initializer_class" translatable="false">com.android.quickstep.QuickstepProcessInitializer</string>
+
+ <string name="user_event_dispatcher_class" translatable="false">com.android.quickstep.logging.UserEventDispatcherExtension</string>
</resources>
diff --git a/go/quickstep/src/com/android/quickstep/OverviewCommandHelper.java b/go/quickstep/src/com/android/quickstep/OverviewCommandHelper.java
index 0fa3d866f..216972cba 100644
--- a/go/quickstep/src/com/android/quickstep/OverviewCommandHelper.java
+++ b/go/quickstep/src/com/android/quickstep/OverviewCommandHelper.java
@@ -15,8 +15,8 @@
*/
package com.android.quickstep;
-import static com.android.systemui.shared.system.ActivityManagerWrapper
- .CLOSE_SYSTEM_WINDOWS_REASON_RECENTS;
+import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
+import static com.android.systemui.shared.system.ActivityManagerWrapper.CLOSE_SYSTEM_WINDOWS_REASON_RECENTS;
import android.annotation.TargetApi;
import android.content.Context;
@@ -25,7 +25,6 @@ import android.os.SystemClock;
import android.view.ViewConfiguration;
import com.android.launcher3.BaseDraggingActivity;
-import com.android.launcher3.MainThreadExecutor;
import com.android.launcher3.logging.UserEventDispatcher;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.ActivityControlHelper.ActivityInitListener;
@@ -43,7 +42,6 @@ public class OverviewCommandHelper {
private final Context mContext;
private final ActivityManagerWrapper mAM;
private final RecentsModel mRecentsModel;
- private final MainThreadExecutor mMainThreadExecutor;
private final OverviewComponentObserver mOverviewComponentObserver;
private long mLastToggleTime;
@@ -51,7 +49,6 @@ public class OverviewCommandHelper {
public OverviewCommandHelper(Context context, OverviewComponentObserver observer) {
mContext = context;
mAM = ActivityManagerWrapper.getInstance();
- mMainThreadExecutor = new MainThreadExecutor();
mRecentsModel = RecentsModel.INSTANCE.get(mContext);
mOverviewComponentObserver = observer;
}
@@ -63,19 +60,19 @@ public class OverviewCommandHelper {
}
mAM.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
- mMainThreadExecutor.execute(new RecentsActivityCommand<>());
+ MAIN_EXECUTOR.execute(new RecentsActivityCommand<>());
}
public void onOverviewShown(boolean triggeredFromAltTab) {
- mMainThreadExecutor.execute(new ShowRecentsCommand());
+ MAIN_EXECUTOR.execute(new ShowRecentsCommand());
}
public void onOverviewHidden() {
- mMainThreadExecutor.execute(new HideRecentsCommand());
+ MAIN_EXECUTOR.execute(new HideRecentsCommand());
}
public void onTip(int actionType, int viewType) {
- mMainThreadExecutor.execute(() ->
+ MAIN_EXECUTOR.execute(() ->
UserEventDispatcher.newInstance(mContext).logActionTip(actionType, viewType));
}
@@ -161,7 +158,7 @@ public class OverviewCommandHelper {
// Otherwise, start overview.
mListener = mHelper.createActivityInitListener(provider::onActivityReady);
mListener.registerAndStartActivity(mOverviewComponentObserver.getOverviewIntent(),
- provider, mContext, mMainThreadExecutor.getHandler(),
+ provider, mContext, MAIN_EXECUTOR.getHandler(),
provider.getRecentsLaunchDuration());
}
diff --git a/go/quickstep/src/com/android/quickstep/TouchInteractionService.java b/go/quickstep/src/com/android/quickstep/TouchInteractionService.java
index 577b17566..19dd82f7f 100644
--- a/go/quickstep/src/com/android/quickstep/TouchInteractionService.java
+++ b/go/quickstep/src/com/android/quickstep/TouchInteractionService.java
@@ -34,8 +34,6 @@ import android.view.MotionEvent;
import com.android.launcher3.Utilities;
import com.android.launcher3.compat.UserManagerCompat;
-import com.android.launcher3.util.LooperExecutor;
-import com.android.launcher3.util.UiThreadHelper;
import com.android.systemui.shared.recents.IOverviewProxy;
import com.android.systemui.shared.recents.ISystemUiProxy;
@@ -139,9 +137,6 @@ public class TouchInteractionService extends Service {
return sConnected;
}
- public static final LooperExecutor BACKGROUND_EXECUTOR =
- new LooperExecutor(UiThreadHelper.getBackgroundLooper());
-
private RecentsModel mRecentsModel;
private OverviewComponentObserver mOverviewComponentObserver;
private OverviewCommandHelper mOverviewCommandHelper;