OSDN Git Service

Take state snapshot in IMMS#attachNewInputLocked()
authorYohei Yukawa <yukawa@google.com>
Tue, 14 Feb 2017 17:40:03 +0000 (09:40 -0800)
committerYohei Yukawa <yukawa@google.com>
Tue, 14 Feb 2017 17:40:03 +0000 (09:40 -0800)
commit357b2f60e147d18af9c8399b346a9e63de1baaf3
treee6c78b5657a486571f0c1c2991a6d0f3cbc46884
parentb37d8bddc9ace8e3a4d66f206e933350b390c805
Take state snapshot in IMMS#attachNewInputLocked()

With this CL, we can finally start taking a state snapshot every time
IMMS#attachNewInputLocked() gets called, which allows us to include
the last N (currently set to 16) history of such snapshots in dumpsys
from InputMethodManagerService:

  adb shell dumpsys input_method

This is a huge milestone for us to start relying more on historical
debugging rather than logcat-based debugging.

Test: Run `adb shell dumpsys input_method` to make sure that
      "mStartInputHistory" entries are updated.
Bug: 35079353
Change-Id: Icb29c4ef0703553ead8654d3255a554de6d1a9b4
services/core/java/com/android/server/InputMethodManagerService.java