Loading
Check that InputDevice isn't null and add annotations
The API 'getDevice' can return null. Let's make sure null isn't dereferenced. Also, add nullability annotations to make it easier to follow. Bug: 227733127 Test: build only Change-Id: Ice514f27d4347528d009969174f09078dfa2afac