Few improvements for Companion widget APIs

1. reset ViewRootImpl#mLastClickToolType for KeyEvents
2. move EditorInfo#mInitialToolType initialization so we dont
   explicitly hold lock for one line of code.

Bug: 233108064
Test: atest CtsInputMethodTestCases

Change-Id: I76d3c4c14928a2eb4c1cda48dd3b9a866963d06f
2 files changed