Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
[android] Pass synthesized eventType to VirtualDisplay platform views
This workaround is to account for flutter/flutter#61169
It is not immediately clear why the actions synthesized by the framework
are different from what is gotten by FlutterView.
  • Loading branch information
Kaushik Iska committed Jul 9, 2020
commit 9fc1d173e70991a50f0edd4e0d987c25215cd45b
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ private MotionEvent toMotionEvent(float density, PlatformViewsChannel.PlatformVi
return MotionEvent.obtain(
trackedEvent.getDownTime(),
trackedEvent.getEventTime(),
trackedEvent.getAction(),
touch.action, // TODO (kaushikiska): https://github.com/flutter/flutter/issues/61169
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Offline discussion: the recommended fix is to leave the virtual display code path unchanged, and have a new toMotionEvent method for hybrid composition, which uses trackedEvent.getAction().

Also, we will need unit tests since the e2e test in https://github.com/flutter/flutter/tree/master/dev/integration_tests/android_views failed at capturing this issue. I will investigate this issue.

touch.pointerCount,
pointerProperties,
pointerCoords,
Expand Down