Commit Graph

2411 Commits

Author SHA1 Message Date
Malcolm Chen
de64f7197a In CarrierTextController replace getPhoneCount with getMaxPhoneCount.
As first step for smooth single SIM to DSDS switch, for DSDS capable
deviced we always allocate objects as if it's in DSDS mode.

Bug: 141388730
Test: unittest and manual

Change-Id: I141689fc55063d87f4f7e5c605a461517beeabe4
Merged-In: I141689fc55063d87f4f7e5c605a461517beeabe4
2019-10-14 14:19:05 -07:00
Treehugger Robot
63e2a95b87 Merge "Use UnlockMethodCache#canSkipBouncer in user switcher" 2019-09-18 17:11:28 +00:00
Joshua Tsuji
c5fab4172a Ignore physics animation tests that have suddenly become flaky.
Test: atest SystemUITests
Change-Id: Ia15f767fdb251338a7e7b15be7836b6928e48ba5
Merged-In: Ia15f767fdb251338a7e7b15be7836b6928e48ba5
(cherry picked from commit 2b991d91c6)
2019-09-16 19:55:35 +00:00
Fabian Kozynski
7eeb7ae118 Use UnlockMethodCache#canSkipBouncer in user switcher
KeyguardMonitor#canSkipBouncer was not updated properly when the phone
was unlocked using fingerprint.

This CL removes that method and changes UserSwitcherController to query
UnlockMethodCache directly, as it was KeyguardMonitor's only client for
that method.

Test: manual unlocking with FP and with pattern
Test: no automated test yet
Bug: 140486529
Merged-In: Idbff4fbabca962c632ff5d78b25418c0502db9a7
Change-Id: Idbff4fbabca962c632ff5d78b25418c0502db9a7
2019-09-05 19:50:39 -04:00
Xin Li
f5defc19a0 DO NOT MERGE - Merge build QP1A.190711.020 into stage-aosp-master
Bug: 139893257
Change-Id: I89559c14cbc17c47f9b43754ec44904b19c73dd3
2019-08-26 18:30:47 +00:00
Xin Li
a770df1d2e DO NOT MERGE - Merge build QP1A.190711.019 into stage-aosp-master
Bug: 139893257
Change-Id: I94fce9c5c0b35cbb88ee27fa4cd037927964d2cd
2019-08-24 05:22:23 +00:00
Ned Burns
5c388cd605 Ensure isTopBucket() gets set when there is just one notification
My descendants will vilify this CL for generations to come. We'll
clean it up for R, but this is our last, best hope for fixing things
in Q.

Bug: 138775282

Test: manual
Change-Id: I615b2f7fddca30dae67dbaab0e5d54a824a4c441
Merged-In: I615b2f7fddca30dae67dbaab0e5d54a824a4c441
(cherry picked from commit 2d35980e72)
(cherry picked from commit 6c34506dd8)
2019-08-14 00:22:30 +00:00
Ned Burns
4863f9be22 Fix issue with media notifs being misbucketed
Previous code assumed that "isHighPriority" == "is in top section",
which is not always true. Media notifs and some other notifs can appear
in the top section even if they're not high priority. Because we detect
section boundaries by iterating through the list until we find the first
notif where isHighPriority == false, we were sometimes drawing the
section boundary way too high. This change creates a new propery,
isInTopSection() that accurately tracks this state.

Setting this value in the proper location would require some seriously
destabilizing refactors, so instead we set it in the list comparator,
which is awful but here are.

Test: manual
Bug: 138320173
Change-Id: I19223720bac534ab92219a2962169097819e8efb
Merged-In: I19223720bac534ab92219a2962169097819e8efb
(cherry picked from commit 8c1b763dcf)
(cherry picked from commit 91e425d793)
2019-07-25 04:11:46 +00:00
Robert Snoeberger
1834518223 Don't animate clock when turning screen off.
This change stops the animation because there isn't a
transition from the no-header state to the music header
state when turning the screen off (to AOD). Since there
isn't a transition, there isn't an animation.

This assumes that there isn't a transition from unlocked to
lock screen. If there is, then there would be an animation
of the music going away while arriving at the lock screen.

Fixes: 137383007
Test: Checked repro steps in bug, clock doesn't animate.
Test: Also checked repro steps when audio is paused, clock doesn't
animate.
Test: atest KeyguardSliceProviderTest.java

Change-Id: If39777340b72bc623d6690bc4f784c7f5c26ea8d
Merged-In: If39777340b72bc623d6690bc4f784c7f5c26ea8d
(cherry picked from commit c51bb548dc)
2019-07-24 02:22:00 +00:00
Dave Mankoff
985eb48cd7 Enable the BrightLineFalsingManager by default on Q.
Bug: 71762354
Change-Id: Icfc6e21d50e08c34168f504ec64bf654ba6cb6a4
Test: atest SystemUITests
(cherry picked from commit b332588e60)
2019-07-23 03:37:00 +00:00
Lucas Dupin
62d8916eac Do not animate wallpaper when wakeAndUnlock
Fixes: 137536016
Test: press power to go to lock scree <-> aod
Test: unlock with fingerprint
Test: trigger AOD2 pulse (look at wallpaper animation)
Test: atest DozeWallpaperStateTest
Change-Id: I46574609a00712bdde5a4652ab5c9b0c04cbeeec
Merged-In: I46574609a00712bdde5a4652ab5c9b0c04cbeeec
(cherry picked from commit 29e30faa4e)
2019-07-19 03:41:05 +00:00
Ned Burns
09f16abd76 Merge "Delay possible re-entrant call to updateNotificationViews()" into qt-dev
am: bce828f157

Change-Id: Ia8cf73996aa49d286880ddd5c9f23b915346ad6a
2019-07-01 14:10:59 -07:00
Ned Burns
b3b4bd390a Delay possible re-entrant call to updateNotificationViews()
NVHM.onDynamicPrivacyChanged() both calls updateNotificationViews() and
could be called by updateNotificationViews(), resulting in very-bad,
no-good re-entrant behavior. It's too late to try to rearchitect the
entire shade to avoid this relationship, so instead we delay a frame
before applying the update.

Bug: 135018709
Test: atest, manual
Change-Id: I0b17d5ba16e272015b10be182a07cae6b29270e6
2019-06-27 19:50:02 -04:00
Lucas Dupin
02a536865a Merge "Avoid stuck wake-locks" into qt-dev
am: 13775aa4bb

Change-Id: Id51fe28e2b53d4d580ddcb437e18914471613504
2019-06-27 01:24:01 -07:00
Lucas Dupin
924010df2d Avoid stuck wake-locks
By having a maximum timeout.

Test: atest WakeLockTest
Fixes: 136001054
Fixes: 135881494
Change-Id: Ie189809191890213ea79f15e76bc1461a3445641
2019-06-27 05:22:26 +00:00
Dave Mankoff
654a92e046 Merge changes from topic "b135715570-test-memory-leaks" into qt-dev
am: c5ab1e8f8a

Change-Id: I3ec11737f8a8b8e959a298622c225480a4c4948a
2019-06-26 07:33:48 -07:00
TreeHugger Robot
c5ab1e8f8a Merge changes from topic "b135715570-test-memory-leaks" into qt-dev
* changes:
  Refactor BrightLineClassifier tests to use significantly less memory.
  Turn off BrightLineClassifier tests until memory leaks can be identified.
2019-06-26 14:08:01 +00:00
Dave Mankoff
f5d210ebd0 Refactor BrightLineClassifier tests to use significantly less memory.
Stop relying so heavily on mockito when it's not necessary. This also
makes tests run significantly faster. Memory usage is now basically flat.

Bug: 135715570
Test: atest SystemUITests
Change-Id: Ifd71e092b19068817600631b5b98a4a8e80a0126
2019-06-25 12:25:41 -04:00
Lucas Dupin
fb1d52c295 Merge "Unregister listeners and reset wake lock" into qt-dev
am: 8dc0ab0aeb

Change-Id: I71c11779640c2c5174a36a088072dc5d222dcb35
2019-06-24 12:50:41 -07:00
Dave Mankoff
cc28d7b6c0 Turn off BrightLineClassifier tests until memory leaks can be identified.
Bug: 135715570
Test: atest SystemUITests
Change-Id: I334ffe87dc7c28367e4f238a9f7928839b7d831c
2019-06-24 14:15:21 -04:00
Lucas Dupin
ba914792ad Unregister listeners and reset wake lock
The ContentProvider might be recreated by the system, so we it's
not necessarily a singleton. We need to cleanup listener registration
and alarms before reattributing the static variable.

Change-Id: I07aec96e77c67d96d31c7e38c85f5ce6f5ef2216
Merged-In: I9bc993f372a8c05258f1778eb3d415af04544714
Fixes: 135344397
Fixes: 135582651
Test: bind and unbind slice various times
Test: atest KeyguardSliceProviderTest
2019-06-24 09:03:12 -07:00
Chiayu Pei
9d75e2fd79 Merge "Revert "Unregister listeners and reset wake lock"" into qt-dev
am: a5be28971c

Change-Id: I7cf114751ff0c2ae1f24301485a52052c42f53b7
2019-06-24 08:09:09 -07:00
Chiayu Pei
a5be28971c Merge "Revert "Unregister listeners and reset wake lock"" into qt-dev 2019-06-24 04:19:13 +00:00
Chiayu Pei
6a8c935767 Revert "Unregister listeners and reset wake lock"
This reverts commit fe107a1621.

Reason for revert: <INSERT REASONING HERE>

Change-Id: Id092c473a8300e014ccd4d941afa4afcdbbf48bc
2019-06-24 01:46:28 +00:00
Lucas Dupin
c736f0a15c Merge "Unregister listeners and reset wake lock" into qt-dev
am: 9b47581ea4

Change-Id: I6c479e080905ca8a8dd2ffc036d384d5eb6d7d2e
2019-06-22 17:34:31 -07:00
Dave Mankoff
59809cd9e1 DO NOT MERGE Allow the new BrightLineFalsingManager to be enabled via PhenoType.
am: e0321d5809

Change-Id: I7caa3c1d9722532167b4c0f91a115602c812619a
2019-06-22 17:31:23 -07:00
Jerry Chang
b84c0786b2 Merge "Fade away wallpapers when long pulse" into qt-dev
am: 14e6d18ec9

Change-Id: I0ee6f6d17990dd423d362e63805eb131bb401b4d
2019-06-22 17:16:17 -07:00
Lucas Dupin
9b47581ea4 Merge "Unregister listeners and reset wake lock" into qt-dev 2019-06-22 20:12:26 +00:00
Lucas Dupin
fe107a1621 Unregister listeners and reset wake lock
The ContentProvider might be recreated by the system, so we it's
not necessarily a singleton. We need to cleanup listener registration
and alarms before reattributing the static variable.

Change-Id: I227842d7272d1edeaa67d776950f369aedb01a91
Merged-In: I227842d7272d1edeaa67d776950f369aedb01a91
Fixes: 135344397
Fixes: 135582651
Test: bind and unbind slice various times
Test: atest KeyguardSliceProviderTest
2019-06-22 19:01:20 +00:00
Dave Mankoff
6c9547a9a5 Merge "DO NOT MERGE Allow the new BrightLineFalsingManager to be enabled via PhenoType." into qt-dev 2019-06-22 15:41:14 +00:00
Dave Mankoff
e0321d5809 DO NOT MERGE Allow the new BrightLineFalsingManager to be enabled via PhenoType.
Test: atest SystemUITests
Bug: 111394067
Change-Id: I0ab9a72d66bf56a56df2de2ad2d247f299d1b748
Merged-In: I0ab9a72d66bf56a56df2de2ad2d247f299d1b748
2019-06-22 14:19:01 +00:00
TreeHugger Robot
14e6d18ec9 Merge "Fade away wallpapers when long pulse" into qt-dev 2019-06-22 11:59:49 +00:00
Selim Cinek
2a3b0f1a28 DO NOT MERGE: Fixed an issue about notification icons on AOD
am: d34e9d889a

Change-Id: If02cf694d7b93b509dcb728e1496690747e1b4c9
2019-06-21 12:05:52 -07:00
TreeHugger Robot
c65d4b728c Merge "DO NOT MERGE: Fixed an issue about notification icons on AOD" into qt-dev 2019-06-21 18:57:25 +00:00
Ned Burns
bed6ce5f87 Merge "Free up memory in the ZigZagClassifierTest." into qt-dev
am: 0031e00da6

Change-Id: I62e3ae11cefeb6304e52b94b332cfc10553bd625
2019-06-21 10:56:24 -07:00
Dave Mankoff
a90fe0a8c3 Free up memory in the ZigZagClassifierTest.
Test: atest SystemUITests
Bug: 135715570
Change-Id: Iddfcf8cc107254c397769b2b3c5251270ec0a3bd
2019-06-21 12:00:59 -04:00
Ned Burns
b9e4f61927 Merge "Add main thread and reentrant asserts to chase down crashes" into qt-dev
am: 4d39c4a7d7

Change-Id: I2378d0c6dea0fb3731e7a33a350775470f6bb9f1
2019-06-20 17:08:24 -07:00
Selim Cinek
d34e9d889a DO NOT MERGE: Fixed an issue about notification icons on AOD
Previously low priority notifications were hidden
on AOD unconditionally which is wrong.

Bug: 135627468
Test: atest SystemUITests
Merged-in: Ia64238f30620d9906aa50c2469121c2653875e8d
Change-Id: Ia64238f30620d9906aa50c2469121c2653875e8d
2019-06-20 23:19:21 +00:00
TreeHugger Robot
4d39c4a7d7 Merge "Add main thread and reentrant asserts to chase down crashes" into qt-dev 2019-06-20 23:11:33 +00:00
Fabian Kozynski
d4202413af Merge "Safeguard against no tiles in QS" into qt-dev
am: 60aabc40a2

Change-Id: Ia491010fffb08f66d2f2f89e6ac9ffb818a71e1b
2019-06-20 15:33:30 -07:00
TreeHugger Robot
60aabc40a2 Merge "Safeguard against no tiles in QS" into qt-dev 2019-06-20 21:42:23 +00:00
Dave Mankoff
7fd2154d6d Merge changes from topic "b111394067-new-falsing-manager" into qt-dev
am: acd240fbb3

Change-Id: Iddabc77d92830eb79327a2ca7a7bd3f9f2f1a786
2019-06-20 13:07:13 -07:00
Fabian Kozynski
6ff5c18cb0 Safeguard against no tiles in QS
In PagedTileLayout:
* Make sure that each page displays at least 1 tile (never 0).
* Make sure that there's at least one page (even if it's empty)

In QSTileHost:
* If the new value of sysui_qs_tiles produces no tiles (but it's not set
to empty), set the tile set to the empty default
@string/quick_settings_tiles

Test: adb shell settings put secure sysui_qs_tiles not-a-valid-tile-spec
Test: atest QSTileHostTest
Fixes: 135023694
Fixes: 135677464
Change-Id: I1e5cf4d2688370001ecae87fc0272acecd48af73
2019-06-20 15:54:45 -04:00
Ned Burns
d4a69f7007 Add main thread and reentrant asserts to chase down crashes
We're seeing crashes due to view hierarchy violations that shouldn't be
possible. Adding some guards to make sure we aren't running into
off-thread hierarchy manipulation or re-entrant calls to the update
code.

Test: manual
Bug: 135018709
Change-Id: I4b1f2bd7e3a6f80384486d59b9f56fc3713537cf
2019-06-20 15:40:55 -04:00
Dave Mankoff
acd240fbb3 Merge changes from topic "b111394067-new-falsing-manager" into qt-dev
* changes:
  Add ZigZagClassifier to the BrightLineFalsingManager.
  Add ProximityClassifier to the BrightLineFalsingManager
  Add DistanceClassifier to the BrightLineFalsingManager
  Add DiagonalClassifier to the BrightLineFalsingManager.
  Add TypeClassifier to the BrightLineFalsingManager.
  Add PointerCountClassifier to the BrightLineFalsingManager.
  Add base class for new falsing manager and classifiers.
2019-06-20 18:05:19 +00:00
Dave Mankoff
89ad24688b Add ZigZagClassifier to the BrightLineFalsingManager.
This rejects swipes that wiggle around too much. Swipes
should be mostly straight.

Bug: 111394067
Test: atest SystemUITests
Change-Id: I43aa1cc62abb47ce43423c3c7c8e58c14dc0db03
2019-06-19 13:50:01 -04:00
Dave Mankoff
8bfbe3348e Add ProximityClassifier to the BrightLineFalsingManager
This requires swipes to travel a minimum distance and/or
fling a minimum distance.

Bug: 111394067
Test: atest SystemUITests
Change-Id: Id7586011a30fdcd9dfef7c937f22c33564829307
2019-06-19 13:50:01 -04:00
Dave Mankoff
65b5769c07 Add DistanceClassifier to the BrightLineFalsingManager
This requires swipes to travel a minimum distance and/or
fling a minimum distance.

Bug: 111394067
Test: atest SystemUITests
Change-Id: Iec90bb73b4108ce803f9247ebc30046e8c1a6a2d
2019-06-19 13:49:55 -04:00
Dave Mankoff
d8efd0d4ed Add DiagonalClassifier to the BrightLineFalsingManager.
This rejects swipes that are too close to 45 degrees.

Bug: 111394067
Test: atest SystemUITests
Change-Id: I45913918e89b965678628e3a6a0431a3db4b085a
2019-06-19 13:45:31 -04:00
Dave Mankoff
fd42bdbb86 Add TypeClassifier to the BrightLineFalsingManager.
This matches an existing falsing classifier that ensure
the general direction of a swipe matches the intended action
(i.e. dismissing a notification should be side to side.)

Bug: 111394067
Test: atest SystemUITests
Change-Id: I861ff0443df6051561991808a760250a68b588fd
2019-06-19 12:48:02 -04:00