OSDN Git Service

Fix emergency only edge case
authorJason Monk <jmonk@google.com>
Thu, 2 Mar 2017 18:58:19 +0000 (13:58 -0500)
committerJason Monk <jmonk@google.com>
Thu, 2 Mar 2017 19:00:05 +0000 (14:00 -0500)
commit8996b94e575b6561fb5be507aecfadf2492bd321
tree0a5c309a2147d651faba66ebaef832cb0b110259
parent00a5f2a65882f5b2814c9449e0ab75b6f2656315
Fix emergency only edge case

When the default sub id doesn't exist and there is only one other
sub id currently, assume that is meant to be the default and use
that to pull emergency state.

Also switch to SparseArray for performance and betterness.

Change-Id: I976de6abb58c46bce0c56793442c0377a39a7071
Fixes: 34119642
Test: runtest systemui
packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java
packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java