Update OHM regions whenever other regions change

- Speculative fix, there are some scenarios where we update the swipe
  touch/assistant regions without updating the OHM regions

Bug: 362039326
Flag: EXEMPT bugfix
Test: Manual
Change-Id: If5c558623073e5185827ae17a162dacf322c74a4
This commit is contained in:
Winson Chung
2024-11-22 16:53:22 +00:00
parent 9163f54158
commit ce1a73829f
4 changed files with 76 additions and 39 deletions
@@ -38,6 +38,8 @@ import static com.android.quickstep.util.ActiveGestureErrorDetector.GestureEvent
import static com.android.quickstep.util.ActiveGestureErrorDetector.GestureEvent.START_RECENTS_ANIMATION;
import static com.android.quickstep.util.QuickstepProtoLogGroup.ACTIVE_GESTURE_LOG;
import android.graphics.Point;
import android.graphics.RectF;
import android.view.MotionEvent;
import androidx.annotation.NonNull;
@@ -499,4 +501,16 @@ public class ActiveGestureProtoLogProxy {
taskId,
packageName);
}
public static void logCreateTouchRegionForDisplay(int displayRotation,
@NonNull Point displaySize, @NonNull RectF swipeRegion, @NonNull RectF ohmRegion,
int gesturalHeight, int largerGesturalHeight, @NonNull String reason) {
if (!enableActiveGestureProtoLog()) return;
ProtoLog.d(ACTIVE_GESTURE_LOG,
"OrientationTouchTransformer.createRegionForDisplay: "
+ "dispRot=%d, dispSize=%s, swipeRegion=%s, ohmRegion=%s, "
+ "gesturalHeight=%d, largerGesturalHeight=%d, reason=%s",
displayRotation, displaySize.flattenToString(), swipeRegion.toShortString(),
ohmRegion.toShortString(), gesturalHeight, largerGesturalHeight, reason);
}
}