Separate logic for publishing motion events

Before a motion event is published, there's some more processing
happening, such as determining which coords should be used.
Let's move that into a separate function to make it more tractable.

Bug: 211379801
Test: atest inputflinger_tests
Change-Id: If373305b546c461e22e4b496d66418f771e9e741
2 files changed