From fd66d09e947b745ff3a87f0b0c500eab9c73a30c Mon Sep 17 00:00:00 2001 From: Vinit Nayak Date: Tue, 28 Nov 2023 00:22:02 +0000 Subject: [PATCH] Revert "Add logs for workspace long press" This reverts commit 74fb544c27623d777eedb55bb4bf5d016fd7cb52. Reason for revert: b/311099513 is now no longer flaky. I suspect these logs may have improved a possibly existing race condition. Let's see if the flake returns w/o these logs. Change-Id: Ib3a06b7d86f4eb5c3c95db9a68bc6eb15aead193 --- .../testing/DebugTestInformationHandler.java | 4 ---- .../launcher3/touch/WorkspaceTouchListener.java | 11 ----------- 2 files changed, 15 deletions(-) diff --git a/ext_tests/src/com/android/launcher3/testing/DebugTestInformationHandler.java b/ext_tests/src/com/android/launcher3/testing/DebugTestInformationHandler.java index c4375d3ba3..29b24b797c 100644 --- a/ext_tests/src/com/android/launcher3/testing/DebugTestInformationHandler.java +++ b/ext_tests/src/com/android/launcher3/testing/DebugTestInformationHandler.java @@ -16,8 +16,6 @@ package com.android.launcher3.testing; -import static com.android.launcher3.testing.shared.TestProtocol.WORKSPACE_LONG_PRESS; -import static com.android.launcher3.testing.shared.TestProtocol.testLogD; import static com.android.launcher3.util.Executors.MAIN_EXECUTOR; import static com.android.launcher3.util.Executors.MODEL_EXECUTOR; @@ -137,12 +135,10 @@ public class DebugTestInformationHandler extends TestInformationHandler { } case TestProtocol.REQUEST_ENABLE_DEBUG_TRACING: - testLogD(WORKSPACE_LONG_PRESS, "enablingDebugTracing"); TestProtocol.sDebugTracing = true; return response; case TestProtocol.REQUEST_DISABLE_DEBUG_TRACING: - testLogD(WORKSPACE_LONG_PRESS, "disablingDebugTracing"); TestProtocol.sDebugTracing = false; return response; diff --git a/src/com/android/launcher3/touch/WorkspaceTouchListener.java b/src/com/android/launcher3/touch/WorkspaceTouchListener.java index a005c607a5..5b6c9e0763 100644 --- a/src/com/android/launcher3/touch/WorkspaceTouchListener.java +++ b/src/com/android/launcher3/touch/WorkspaceTouchListener.java @@ -25,11 +25,9 @@ import static com.android.launcher3.LauncherState.ALL_APPS; import static com.android.launcher3.LauncherState.NORMAL; import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_ALLAPPS_CLOSE_TAP_OUTSIDE; import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_WORKSPACE_LONGPRESS; -import static com.android.launcher3.testing.shared.TestProtocol.WORKSPACE_LONG_PRESS; import android.graphics.PointF; import android.graphics.Rect; -import android.util.Log; import android.view.GestureDetector; import android.view.HapticFeedbackConstants; import android.view.MotionEvent; @@ -41,7 +39,6 @@ import com.android.launcher3.AbstractFloatingView; import com.android.launcher3.CellLayout; import com.android.launcher3.DeviceProfile; import com.android.launcher3.Launcher; -import com.android.launcher3.Utilities; import com.android.launcher3.Workspace; import com.android.launcher3.config.FeatureFlags; import com.android.launcher3.dragndrop.DragLayer; @@ -112,10 +109,6 @@ public class WorkspaceTouchListener extends GestureDetector.SimpleOnGestureListe mTouchDownPoint.set(ev.getX(), ev.getY()); // Mouse right button's ACTION_DOWN should immediately show menu if (TouchUtil.isMouseRightClickDownOrMove(ev)) { - if (Utilities.isRunningInTestHarness()) { - Log.d(WORKSPACE_LONG_PRESS, "longPress from mouseHandling timeout: +" - + ViewConfiguration.getLongPressTimeout()); - } maybeShowMenu(); return true; } @@ -199,10 +192,6 @@ public class WorkspaceTouchListener extends GestureDetector.SimpleOnGestureListe @Override public void onLongPress(MotionEvent event) { - if (Utilities.isRunningInTestHarness()) { - Log.d(WORKSPACE_LONG_PRESS, "longPress from gestureHandler timeout: " + - ViewConfiguration.getLongPressTimeout()); - } maybeShowMenu(); }