Fix Keyboard won't display when RemoteInput active

Commit 970d9d2 instroduced IME focus controller which
added a new method View#hasImeFocus to restrict the IME keyboard
is focusble only when the focused window won't have either FLAG_NOT_FOCUSABLE
or FLAG_ALT_FOCUSABLE_IM flags.

Since NotificationShadeWindowController will unset both flags when
RemoteInput active.

But, in ImeFocusControler#onTraversal won't keep update View'ss mHasImeFocus
state, it will affect IME focus handle correctness.

Hense, it needs to fix View#hasImeFocus state update issue.

Fix: 148489857
Bug: 141738570
Test: manual as following steps:
 0) make EditTextVariations
 1) adb install -r EditTextVariations.apk
 2). adb shell am start -n com.android.inputmethod.tools.edittextvariations/.EditTextVariations
 3). Tap the 3-dot menu on the EditTextVariations
 4). Tap `Direct Reply` on the menu
 5). Open notification drawers
 6) Try to direct-reply on the notification, expect soft-keyboard should come up after step 6)

Change-Id: I8d4fff94ba9313b773bc27fcbd019cc88580d3e9
(cherry picked from commit 655c367badbeb6c9d46e59fb117fe1d01928cf6d)
2 files changed