From 926470f15264246c9584033785ead8fb693bf3bd Mon Sep 17 00:00:00 2001 From: Jeff DeCew Date: Tue, 10 Jan 2023 21:22:20 +0000 Subject: [PATCH] Use MotionEvent.getEventTime() instead of SystemClock.uptimeMillis() This should be perfectly safe since this value is only used for reporting the timestamp to ActivityOptions.SourceInfo, and getEventTime is a timestamp in the uptime clock base. Change-Id: Ie6d55f85dba083834e76edd826c5eca52fda1cf0 Fixes: 265053878 Test: treehugger --- .../notification/row/ActivatableNotificationViewController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ActivatableNotificationViewController.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ActivatableNotificationViewController.java index c4961029dc331..b084a765956d4 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ActivatableNotificationViewController.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ActivatableNotificationViewController.java @@ -109,7 +109,7 @@ public class ActivatableNotificationViewController return true; } if (ev.getAction() == MotionEvent.ACTION_UP) { - mView.setLastActionUpTime(SystemClock.uptimeMillis()); + mView.setLastActionUpTime(ev.getEventTime()); } // With a11y, just do nothing. if (mAccessibilityManager.isTouchExplorationEnabled()) {