Commit Graph

14822 Commits

Author SHA1 Message Date
Treehugger Robot
8513ac2afc Merge "Update language to comply with Android's inclusive language guidance" am: 558a921d81 am: 927f0f7453 am: 1ff037880a am: 6671acef6e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1382388

Change-Id: Icb0ab4bed8a74674fcfbdd7c8e0885a2994ec0cb
2020-09-11 18:17:49 +00:00
Treehugger Robot
6671acef6e Merge "Update language to comply with Android's inclusive language guidance" am: 558a921d81 am: 927f0f7453 am: 1ff037880a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1382388

Change-Id: I4ec82de3182802b71ebe8c5a9ac2b9bdaaa58cdf
2020-09-11 17:29:36 +00:00
Treehugger Robot
1ff037880a Merge "Update language to comply with Android's inclusive language guidance" am: 558a921d81 am: 927f0f7453
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1382388

Change-Id: I03a1373dcc1cdcf0d73536d98d5205317183cdef
2020-09-11 16:48:39 +00:00
Lais Andrade
e5c953b7ec Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

BUG: 162536543
Test: N/A
Change-Id: Ied240c486df4072ca6301511aa3419f746404afa
2020-09-11 14:31:20 +00:00
Tiger Huang
d541d1d4fd Update requested state after applying pending frames am: dfc8abb1ff
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12526908

Change-Id: I40156abe8952ae5b9ed36b3bc6ae5b854380e14e
2020-09-09 19:30:32 +00:00
Tiger Huang
dfc8abb1ff Update requested state after applying pending frames
When there is an insets animation, we will stop updating insets source
frames until the animation is done. The previous logic didn't update the
frames within the requested state while the animation is done. And the
frames was relied by InsetsPolicy while playing transient bar animation.
If the frames don't match the display, the insets would be wrong, and
the animation wouldn't be played correctly.

Fix: 161134197
Test: atest InsetsControllerTest
Merged-In: Id8f3c1956fbfe3ad16f167ff76297dde6c634e81
Change-Id: Id8f3c1956fbfe3ad16f167ff76297dde6c634e81
(cherry picked from commit 23c75281ef)
2020-09-07 16:09:08 +08:00
Xin Li
c8c8e8e8be Merge RP1A.200720.011
Bug: 167588565
Merged-In: Iec7a26ecd68aca9c7a38cc8f441197a8237b0c8c
Change-Id: Ia8f5f008bc1f77115b644ab996aedc892fab68e7
2020-09-02 12:34:37 -07:00
Tiger Huang
63b0b6e6bb Make display frame compatible am: 677078e872
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12500988

Change-Id: Ie735f38e26cd6fa5c71aef0dbf70e87072b1ae4c
2020-09-02 12:19:24 +00:00
Tiger Huang
b95d91a1ba Merge "Compare with oldSoftInputMode after restoring softInputMode" into rvc-qpr-dev am: 6a1829d14a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12500989

Change-Id: I603f8ba6efa2b4536da8a039c06aefac63f57501
2020-09-02 12:18:58 +00:00
Tiger Huang
677078e872 Make display frame compatible
The display frame is used to limit the windows boundary. The frame is
the same as the parent frame in most cases if the window is not
attched. However, if a window doesn't have any layout related
window/sysui flags and the soft input mode is not ADJUST_RESIZE, the
display frame doesn't need to be inset by IME (but the parent frame
does).

Fix: 163435784
Test: atest ViewRootImplTest DisplayPolicyLayoutTests
Merged-In: Ia61933120027642d1f0e0a490546071ca2b6c853
Change-Id: Ia61933120027642d1f0e0a490546071ca2b6c853
2020-09-02 11:38:21 +00:00
Tiger Huang
e80e94182c Compare with oldSoftInputMode after restoring softInputMode
... of mWindowAttributes. Apps might update LayoutParams with
softInputMode unspecified on applying insets, and this can cause
infinite loop in the previous logic, because we would auto-compute
softInputMode for the unspecified one, which makes app's softInputMode
never be the same as the one in ViewRootImpl.mWindowAttributes.

Fix: 163009478
Test: Print stack trace before calling requestFitSystemWindows() and
      follow the steps in the bug.
Test: Open Messages, go to attachments, reopen IME
Change-Id: I2341121b69209688c2f6fb033f51611b21422a04
2020-09-02 06:48:08 +00:00
Xin Li
628590d7ec Merge Android R (rvc-dev-plus-aosp-without-vendor@6692709)
Bug: 166295507
Merged-In: I3d92a6de21a938f6b352ec26dc23420c0fe02b27
Change-Id: Ifdb80563ef042738778ebb8a7581a97c4e3d96e2
2020-08-31 21:21:38 -07:00
Tiger Huang
606a45341b Merge "Refine system bar position restoring" into rvc-d1-dev am: 6383ac86ca
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12406774

Change-Id: I9b1e07559a3194b22d07d7b107d780abc4f1bcc9
2020-08-20 11:05:46 +00:00
Tiger Huang
444e8dc6ce Refine system bar position restoring
The previous logic restores the system bar as long as its insets source
is visible. There can be a timing issue that if the user swipes to show
transient bars while an immersive app just becomes the control target
but the hide-bar info haven't sent to WM yet, WM will re-show the bar
incorrectly.

This CL uses the requested visibility and the behavior to decide if we
should restore the postion and the visibility.

This CL also refines and caches the arguments of showTransient. In this
way, we don't have to create the array every time while invoking that
method.

Fix: 161247175
Test: atest InsetsPolicyTest
Merged-In: Idef314dfe6625399b88b3dacb4c74c7071453497
Change-Id: Idef314dfe6625399b88b3dacb4c74c7071453497
(cherry picked from commit 533682ebb3)
2020-08-19 16:13:25 +00:00
Tiger Huang
02b0205641 Update requested state after applying pending frames am: 23c75281ef
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12400337

Change-Id: I955a32723913c7cc238ce38e8c97328295dae27c
2020-08-19 15:58:11 +00:00
Tiger Huang
23c75281ef Update requested state after applying pending frames
When there is an insets animation, we will stop updating insets source
frames until the animation is done. The previous logic didn't update the
frames within the requested state while the animation is done. And the
frames was relied by InsetsPolicy while playing transient bar animation.
If the frames don't match the display, the insets would be wrong, and
the animation wouldn't be played correctly.

Fix: 161134197
Test: atest InsetsControllerTest
Merged-In: Id8f3c1956fbfe3ad16f167ff76297dde6c634e81
Change-Id: Id8f3c1956fbfe3ad16f167ff76297dde6c634e81
2020-08-19 20:42:39 +08:00
Tiger Huang
3b3ddb3574 Dispatch insets to client if mState is changed am: f8175d1a5b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12406767

Change-Id: I28e6b34667d53eb49f8b167964625342f8c29520
2020-08-19 12:19:31 +00:00
Tiger Huang
efee1a6ba0 Merge "Refine system bar position restoring" into rvc-qpr-dev am: 1adfc8b85c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12293070

Change-Id: I23e07b7e45535df955ff56cf98e760e95023bd09
2020-08-19 12:07:08 +00:00
Tiger Huang
1adfc8b85c Merge "Refine system bar position restoring" into rvc-qpr-dev 2020-08-19 11:57:15 +00:00
Tiger Huang
f8175d1a5b Dispatch insets to client if mState is changed
Previous logic in onStateChanged notifies insetsChanged based on the
change of mLastDispatchedState, which can make us dispatch redundant
insets changes to the app.

In this CL, we only notifies insetsChanged if mState is really changed
in onStateChanged -- we use the final mState (after updateState and
applyLocalVisibilityOverride) to compare with the one before changing.

Fix: 161924448
Test: atest InsetsControllerTest WindowInsetsControllerTests
Test: Swipe up to home while IME open and see if there is any jank
Merged-In: Ia536cdf76805caa56ca1b6eaf2b3db83b6ecd94e
Change-Id: Ia536cdf76805caa56ca1b6eaf2b3db83b6ecd94e
2020-08-19 15:32:53 +08:00
Tiger Huang
dab8b9b114 Merge "Update requested state after applying pending frames" into rvc-qpr-dev am: 943589cf45
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12371142

Change-Id: Ia3b2ca6b9118da1c2af064033e67d98c6d2835df
2020-08-19 00:37:33 +00:00
Tiger Huang
943589cf45 Merge "Update requested state after applying pending frames" into rvc-qpr-dev 2020-08-19 00:25:22 +00:00
Tiger Huang
533682ebb3 Refine system bar position restoring
The previous logic restores the system bar as long as its insets source
is visible. There can be a timing issue that if the user swipes to show
transient bars while an immersive app just becomes the control target
but the hide-bar info haven't sent to WM yet, WM will re-show the bar
incorrectly.

This CL uses the requested visibility and the behavior to decide if we
should restore the postion and the visibility.

This CL also refines and caches the arguments of showTransient. In this
way, we don't have to create the array every time while invoking that
method.

Fix: 161247175
Test: atest InsetsPolicyTest
Merged-In: Idef314dfe6625399b88b3dacb4c74c7071453497
Change-Id: Idef314dfe6625399b88b3dacb4c74c7071453497
2020-08-18 20:53:41 +08:00
Treehugger Robot
d013c0ac14 Merge "Update InputMethodInfo to comply with Android's inclusive language guidance" am: 2e1b52b1d1 am: 453023d999 am: cb5c7ad1fa am: bd9e396d1c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1401337

Change-Id: Ie40b2f4241e4ed952f95fe41590e93243999aff6
2020-08-18 03:51:02 +00:00
Treehugger Robot
bd9e396d1c Merge "Update InputMethodInfo to comply with Android's inclusive language guidance" am: 2e1b52b1d1 am: 453023d999 am: cb5c7ad1fa
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1401337

Change-Id: Ia225a60079ace7062e7082be0e7f768dde5f908f
2020-08-18 03:38:49 +00:00
Treehugger Robot
cb5c7ad1fa Merge "Update InputMethodInfo to comply with Android's inclusive language guidance" am: 2e1b52b1d1 am: 453023d999
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1401337

Change-Id: If474261934e1e78e5144b80804e95818e73b8b0c
2020-08-18 03:26:28 +00:00
Tarandeep Singh
2662fabd35 Update InputMethodInfo to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

Bug: 162536543
Change-Id: Id5bf6719180fe6214ccffec6e9c4d031cd298638
Test: atest InputMethodInfoTest
2020-08-14 23:30:40 +00:00
Julia Reynolds
d3dc8e79cf Merge "Remove app ops indicators from notifications" into rvc-qpr-dev am: 2659836775
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12361488

Change-Id: I70c1dd2665b51c442484577f0077ad4bebc0577d
2020-08-14 17:43:43 +00:00
Julia Reynolds
2778b62f1d Remove app ops indicators from notifications
Test: atest
Bug: 163076432
Change-Id: I5b7514f765811ffd3b0aca63d0108591755974ab
Merged-In: I5b7514f765811ffd3b0aca63d0108591755974ab
2020-08-14 15:02:02 +00:00
Tiger Huang
1a53789bc8 Update requested state after applying pending frames
When there is an insets animation, we will stop updating insets source
frames until the animation is done. The previous logic didn't update the
frames within the requested state while the animation is done. And the
frames was relied by InsetsPolicy while playing transient bar animation.
If the frames don't match the display, the insets would be wrong, and
the animation wouldn't be played correctly.

Fix: 161134197
Test: atest InsetsControllerTest
Change-Id: Id8f3c1956fbfe3ad16f167ff76297dde6c634e81
2020-08-13 14:58:06 +00:00
Adrian Roos
b0591f4068 Merge changes I05b83c47,I5a840ec1 am: 49c52755d2 am: befa7e20f7 am: 9e07e38369 am: a9d806ec0b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1398233

Change-Id: Idffc4452f8845ca937d22291010ee510b076c18c
2020-08-12 18:37:39 +00:00
Adrian Roos
a9d806ec0b Merge changes I05b83c47,I5a840ec1 am: 49c52755d2 am: befa7e20f7 am: 9e07e38369
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1398233

Change-Id: I2e4ded90bf752cf2b9460226c0bd5b97df38b907
2020-08-12 18:21:37 +00:00
Adrian Roos
9e07e38369 Merge changes I05b83c47,I5a840ec1 am: 49c52755d2 am: befa7e20f7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1398233

Change-Id: I15c7258ee3b45f7c9bf65e627140fe7fb3fccf95
2020-08-12 18:01:26 +00:00
Adrian Roos
38a97a4947 Introduce "Fallback InputConnection" term to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

Bug: 162536543
Test: make droid
Change-Id: I05b83c478e7a8bc95784ad448ed09248d92767ad
2020-08-12 12:52:47 +02:00
Tiger Huang
c8f8eefeab Merge "Dispatch insets to client if mState is changed" into rvc-qpr-dev am: 046b604fd4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12239625

Change-Id: I836a29f8662ab19756d3e7401f2582c26b7fdd8e
2020-08-06 21:11:46 +00:00
Tiger Huang
046b604fd4 Merge "Dispatch insets to client if mState is changed" into rvc-qpr-dev 2020-08-06 20:58:40 +00:00
Tiger Huang
b6478edb09 Dispatch insets to client if mState is changed
Previous logic in onStateChanged notifies insetsChanged based on the
change of mLastDispatchedState, which can make us dispatch redundant
insets changes to the app.

In this CL, we only notifies insetsChanged if mState is really changed
in onStateChanged -- we use the final mState (after updateState and
applyLocalVisibilityOverride) to compare with the one before changing.

Fix: 161924448
Test: atest InsetsControllerTest WindowInsetsControllerTests
Test: Swipe up to home while IME open and see if there is any jank
Change-Id: Ia536cdf76805caa56ca1b6eaf2b3db83b6ecd94e
2020-08-06 17:26:57 +08:00
Chavi Weingarten
ef89319e01 Merge "Revert "Reparent bounds layer if surface was replaced."" into rvc-d1-dev am: 15e6f37a16 am: 1812833eb2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12308823

Change-Id: Ibe64a1ed3a0d03c4e78777268f551a07ca3537fe
2020-08-06 01:56:41 +00:00
Chavi Weingarten
464e51527f Merge "Revert "Reparent bounds layer if surface was replaced."" into rvc-d1-dev am: 15e6f37a16
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12308823

Change-Id: Iad5abb3a1498bbc45359a6e454aa446a0fc983d4
2020-08-06 01:41:08 +00:00
Chavi Weingarten
1812833eb2 Merge "Revert "Reparent bounds layer if surface was replaced."" into rvc-d1-dev am: 15e6f37a16
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12308823

Change-Id: I49889d6e90ed4d8ce33ca773eeeb3ab7e4a43924
2020-08-06 01:39:49 +00:00
Lais Andrade
0e81d7ec8e Merge "Fix typo on View.verifyDrawable method javadoc" am: efd27a83f5 am: 8b8c8f1004 am: 655eb212ec am: 388881b89a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1386078

Change-Id: Iad15300f86c480874afc71a291eb698a70c9fd52
2020-08-05 13:05:19 +00:00
Lais Andrade
655eb212ec Merge "Fix typo on View.verifyDrawable method javadoc" am: efd27a83f5 am: 8b8c8f1004
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1386078

Change-Id: Ie8720fc2f94420e5d01b03047aa1579c46f8f203
2020-08-05 12:21:32 +00:00
Lais Andrade
50ef151f8b Fix typo on View.verifyDrawable method javadoc
Fix: b/157335615
Test: N/A, only changing documentation
Change-Id: I30f869bdaac5fb6b87ea56a4416e619b46565113
2020-08-05 08:20:08 +00:00
Chavi Weingarten
e6c662098d Revert "Reparent bounds layer if surface was replaced."
This was intended to fix a reparent issue when preserving
surfaces before the app was closed. That is no longer happening
so this change is no longer needed.

The reason this causes the flicker is it waits to reparent until
next frame. However, the frame can be submitted before WM gets a
chance to show the new Surface since that request is sent to WM.

Therefore, the SurfaceView can end up getting reparented to the
new SurfaceControl before the new SurfaceControl is visible,
causing it to be hidden for a few frames.

This reverts commit c1dcac9568.

Reason for revert: b/162377855

Fixes: 162377855
Test: Split screen with SurfaceView doesn't flicker
Change-Id: Ic7a209b7aa66e278b99a526d8427f140b31de0f6
2020-08-04 20:36:49 +00:00
Kevin Hufnagle
8cdf49be4c Merge "docs: Changes "their" to "the" in 2 places" into rvc-dev am: 24ed56bd0c am: b4937f485e am: 46128203a5
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12286685

Change-Id: I9381dd6d6ef0a03178c50704f524ca68e08eee83
2020-08-03 23:28:40 +00:00
Kevin Hufnagle
46128203a5 Merge "docs: Changes "their" to "the" in 2 places" into rvc-dev am: 24ed56bd0c am: b4937f485e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12286685

Change-Id: If1a6f104218936954bdd5d689fcc762efca2b99b
2020-08-03 23:03:00 +00:00
Kevin Hufnagle
e500a9f38b Merge "docs: Changes "their" to "the" in 2 places" into rvc-dev am: 24ed56bd0c am: b4937f485e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12286685

Change-Id: I034901e5722e469498fd6c871de294edbb466a6e
2020-08-03 23:02:59 +00:00
Kevin Hufnagle
772d87c0e1 Merge "docs: Changes "their" to "the" in 2 places" into rvc-dev am: 24ed56bd0c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12286685

Change-Id: Icce4c3e0a7029fc9e31b4f767a5da0c3034ed08f
2020-08-03 22:51:34 +00:00
Kevin Hufnagle
24ed56bd0c Merge "docs: Changes "their" to "the" in 2 places" into rvc-dev 2020-08-03 22:26:36 +00:00
Kevin Hufnagle
e39427591a docs: Changes "their" to "the" in 2 places
When referring to a client (piece of software), it's better not to use
a personified pronoun, such as "his" or "their". Changed to "the".

Change-Id: I5d79e70a9135d6f1e8da493fcdd50921b9696e31
Test: none (docs-only change)
Bug: 160937339
2020-07-31 23:28:24 +00:00