Skip to content

Commit 3f1679c

Browse files
committed
Remove an unnecessary sanity check
This is causing issues with MotionEvents built by various tools such as DRT. The check itself doesn't seem strictly necessary, and it is easier to remove the check than fix all the tools and tests Change-Id: I74bf85307956b5858042fbe23f87ed2b87132f17
1 parent f804ba1 commit 3f1679c

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

core/java/android/webkit/WebViewInputDispatcher.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -269,9 +269,8 @@ public void setWebKitWantsTouchEvents(boolean enable) {
269269
*/
270270
public boolean postPointerEvent(MotionEvent event,
271271
int webKitXOffset, int webKitYOffset, float webKitScale) {
272-
if (event == null
273-
|| (event.getSource() & InputDevice.SOURCE_CLASS_POINTER) == 0) {
274-
throw new IllegalArgumentException("event must be a pointer event");
272+
if (event == null) {
273+
throw new IllegalArgumentException("event cannot be null");
275274
}
276275

277276
if (DEBUG) {

0 commit comments

Comments
 (0)