When IME window switches from current display to another display and back quickly,
system will re-bind InputMethodService to re-attach window token for each moving,
the IME service lifecycle will be onBind -> onUnBind -> onDestroy -> onBind.
Ideally, system will deliver window token when onServiceConnected and system should
only receive one onServiceConnected when the last service bound.
But due to user switch display very quick, before unbind service callbacked from client,
the next bind service request comes, caused the connection exists in system side and
client will then callback 2 onServiceConnected to system.
Since CL [1] introduced InputMethodPrivilegedOperationsRegistry to deal with token
registraction singleton-ness, the exception will be thrown for above case due to
the duplicate window token passed to client.
Add InputMethodPrivilegedOperationsRegistry#isRegistered to check if the token
already registered, if so, skip this duplicate initialization request.
[1]: I4a61470f06ffac5f7a512536f8431489db0108f4
Fix: 133624278
Test: manual as below steps:
1) Settings > Developer options, enable "Simulated display" & "force desktop mode"
2) Reboot device.
3) Launch app from simulated display.
4) Launch app from primary display (i.e. contacts), focus EditText to show IME.
5) Tapping primary & simulated display repeatly & quickly.
6) See if any exception log from IME application. (i.e. Gboard)
Change-Id: Ie6bfbae735724fe744590e715124d2737d2b665d
Created a string type of phenotype flag which contains the clock plugin
service names that are not allow to be shown. Each service name is
seperated by a comma(",").
Test: atest com.android.keyguard.clock.ClockManagerTest
Bug: 133406302
Change-Id: I51c00b03ec56eaf4de7cab91073deeeb73610f93
Improves behavior modes to use more reliable callback mechanisms. Added
phenotype flag hooks for control of behavior and behavior parameters.
Added more robust null guarding.
Test: Tested locally
BUG:132983599
Change-Id: I42039152836071941d6b4f1cafb3670c62a65824
* changes:
Add one more test for VPN usage stats.
Addressing comments for http://ag/7700679.
NetworkStatsService: Fix getDetailedUidStats to take VPNs into account.
Take all VPN underlying networks into account when migrating traffic for VPN uid.
Turns out there's a secondary layout used by resolver which does not
contain R.id.empty. Check for null.
Bug: 133707284
Test: Open PDF file through resolver
Change-Id: I311f1c1d2fa6edcebc81d9056755884b1585a7cb
Continue to hide the direct share area for low ram devices. Make sure
the A-Z list loads properly.
Bug: 132342311
Test: Use low ram device
Change-Id: I66b58af3994e034e4d870286ef62ba4a9289e083
VPN uid.
(cherry picked from commit 95aa6d446f)
Bug: 113122541
Bug: 120145746
Test: atest FrameworksNetTests
Test: Manually verified on device that stats from VPN UID are moved
appropriately based on its declared underlying network set.
Test: vogar --mode app_process --benchmark NetworkStatsBenchmark.java
Change-Id: I7f368c5970b2dcb969fe0daf5ef44edb1f51d09d