Skip to content
Commit 152eacec authored by Ming-Shin Lu's avatar Ming-Shin Lu
Browse files

Let IME#onFinishInput called without dup onStartInput when screen-off

Also called IME#onStartInput without dup onFinishInput when screen-on,
to fix the long-standing IME input connection lifecycle issue when
device screen state changes.

Bug: 156215187
Bug: 26851566
Test: atest InputMethodStartInputLifecycleTest
Test: manual as below steps
      0) Enable InputMethodService debug flag.
      0-1) In Settings -> Develop options -> AppCompatibility Changes,
           Select Gboard and then toggle
           "FINISH_INPUT_NO_FALLBACK_CONNECTION" change.
      1) Launch a app with focused a editor and show soft-input
      2) When device screen turned-off, will see InputMethodService only
         callbacks below logs:
           CALL: doFinishInput
           CALL: onFinishInputView
           CALL: onFinishInput
      3) When device screen turned-on, will see InputMethodService only
         callbacks below logs:
           CALL: onStartInput
           CALL: onStartInputView

Change-Id: I8a657e75e274d842fb46b60375f6aeafeab96a59
parent 976aa3d4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment