Merge: Android: extract input_events and clean up