Commit Graph

14597 Commits

Author SHA1 Message Date
Jorim Jaggi
8a3dd6f771 Merge "Decouple InsetsController from ViewRootImpl" into rvc-dev am: 1db61c9a6e am: f26b0c6672 am: fa254e366e am: 61f298d90f
Change-Id: I0dc379cbd5a9f72b4c8161e133dc8ec3cf8b2915
2020-04-29 15:15:50 +00:00
Jorim Jaggi
1db61c9a6e Merge "Decouple InsetsController from ViewRootImpl" into rvc-dev 2020-04-29 14:35:10 +00:00
Jorim Jaggi
bf87c15b33 Decouple InsetsController from ViewRootImpl
Such that all it's goodness can also be used in context when
ViewRootImpl isn't available, like the SystemUI controller used
for Car and Split

Test: InsetsControllerTest
Fixes: 154631128
Change-Id: I54a3f8a34810472d9273e4627a7811b7abd0863f
2020-04-29 14:00:09 +02:00
Rob Carr
fe2f23525f Merge "BLAST: Avoid JNI call on creation" into rvc-dev am: 6fcbf83d5e am: 8747dafc25 am: fdc1604f8b am: 5be7d2103e
Change-Id: I24b0d9957cccabb8bd6125aedbcaf8148ba0e86c
2020-04-29 04:52:04 +00:00
Rob Carr
6fcbf83d5e Merge "BLAST: Avoid JNI call on creation" into rvc-dev 2020-04-29 03:59:14 +00:00
Marin Shalamanov
f4733dd8ac Merge "Change the type of display port from byte to int" 2020-04-28 12:25:33 +00:00
Alec Mouri
dd097c3e12 Merge "Remove exposed hidden apis in Point.java" 2020-04-28 01:29:02 +00:00
TreeHugger Robot
713e9bdb88 Merge "Support WRAP_CONTENT in InlineSuggestion#inflate" into rvc-dev am: 5e9aed81d0 am: 820cf90774 am: be1ec62c81 am: ad5f34069a
Change-Id: I021c1d5c7adafc1590bba0a1ec431051b7b3883e
2020-04-28 00:40:43 +00:00
Diego Vela
6009446ba9 Merge "Fix default constructor for DisplayAdjustments" into rvc-dev am: 7383ef7a6c am: a9c8016c75 am: bdf1d8c10c am: b8e8690725
Change-Id: I70526b5331014138422d49583034487ff3bcde22
2020-04-28 00:40:06 +00:00
TreeHugger Robot
5e9aed81d0 Merge "Support WRAP_CONTENT in InlineSuggestion#inflate" into rvc-dev 2020-04-27 23:52:59 +00:00
Diego Vela
7383ef7a6c Merge "Fix default constructor for DisplayAdjustments" into rvc-dev 2020-04-27 23:41:45 +00:00
TreeHugger Robot
3c480fbd20 Merge "Remove DisplayListCanvas" 2020-04-27 22:53:58 +00:00
Evan Rosky
31d55f325d Merge "Connect systemwindow root with accessibility" into rvc-dev am: db49a262de am: bfdaff3dfe am: fcacba52f3 am: 7ec98fadda
Change-Id: Ic14cfca94b450519f97fdd7062d71bb63d15fcd3
2020-04-27 22:31:30 +00:00
Feng Cao
bd26abbc5b Support WRAP_CONTENT in InlineSuggestion#inflate
Test: atest android.autofillservice.cts.inline
Bug: 154887895

Change-Id: Ie420bd40e8f0fb7d6e6b1e47ed0f41dc3f85b25e
2020-04-27 15:12:14 -07:00
Evan Rosky
db49a262de Merge "Connect systemwindow root with accessibility" into rvc-dev 2020-04-27 21:52:07 +00:00
Leon Scroggins III
2d1eb2b9e5 Remove DisplayListCanvas
Bug: 152983829
Bug: 119066174
Test: make; flash and boot

This was already renamed to RecordingCanvas, which is in the graphics
package. It was revived in the old location to temporarily support apps
that were relying on the old name. Currently go/nonsdk-dash shows no
usages, neither via runtime logging nor via static analysis.

RecordingCanvas also cannot refer to this hidden class in the view
package once graphics is its own mainline module. Remove the hidden
class, which was the original plan anyway.

Restore RecordingCanvas' constructor back to private, since it had been
changed to protected as part of the revived DisplayListCanvas.

Change-Id: I7ae1fa043811e361efa6c28753a92bb9c30a7198
2020-04-27 16:46:36 -04:00
Marin Shalamanov
41cb66fa00 Change the type of display port from byte to int
Using byte for display port is error prone since ports
are in the range [0, 255] and bytes have the range [-128, 127].
This way we need to downcast from int to byte in order to write a
value to display port and also we need to call Byte.toUnsignedInt
every time we want to consume it.

Test: m services
Bug: 153334857
Change-Id: I4dce87c0a411c5d447f62cc5564eb4b8a8fb75f0
2020-04-27 22:11:29 +02:00
Robert Carr
ae8e0aea36 BLAST: Avoid JNI call on creation
JNI calls aren't free and we don't need to burn one
to call update with the values we just passed in.

Bug: 152501005
Test: Existing tests pass
Change-Id: Iaf272edb03d4ec195b75e9ef7e6c122604025dcb
2020-04-27 12:54:11 -07:00
Rob Carr
33293c2173 Merge "BLAST: Two start-up optimizations" into rvc-dev am: 9005cdcf01 am: 6008585fa0 am: 572ee349bb am: 10be22241d
Change-Id: I11fb2bb7ca7a3662e0ccddc6f5290a14f3576bde
2020-04-27 18:28:34 +00:00
Taran Singh
ad8447e04c Merge "Add test for ImeInsetsSourceConsumer" into rvc-dev am: 88191952ec am: cfbe05276f am: bb7fa72121 am: 428d8f4896
Change-Id: Ic857b20aad78092563a340915aa7aff42394ef06
2020-04-27 18:26:46 +00:00
Rob Carr
9005cdcf01 Merge "BLAST: Two start-up optimizations" into rvc-dev 2020-04-27 17:20:42 +00:00
Taran Singh
88191952ec Merge "Add test for ImeInsetsSourceConsumer" into rvc-dev 2020-04-27 17:08:05 +00:00
Charles Chen
cc6013812e Merge changes Ida26b961,I1d416b9c into rvc-dev am: 413ce328e5 am: f8bc6fe4fa am: 2ca88b4ce2 am: b88c351a7a
Change-Id: I9a6f82f7274dba074dcf699009bcfff167e1fe76
2020-04-27 10:08:12 +00:00
Charles Chen
413ce328e5 Merge changes Ida26b961,I1d416b9c into rvc-dev
* changes:
  Fix error in DecorView's ViewConfiguration
  Fix DecorView error about non-visual context
2020-04-27 08:57:58 +00:00
Charles Chen
6661575791 Fix DecorView error about non-visual context
This error showed because DecorContext uses application context
to get WindowManager. This CL changes to use PhoneWindow to obtain
WindowManager instance. Also refactor ctr to obtain context from
PhoneWindow.

Bug: 152806048
Test: manual - enable strict mode and check the error log not shown.
Test: atest DecorContextTest
Test: atest MemoryTests#testActivityRecreation
Change-Id: I1d416b9cdb015c9bc3553571041f3b14bb9da5da
2020-04-27 16:37:46 +08:00
TreeHugger Robot
97022c4509 Merge "Keeps the served view of the window when focus to the next window" into rvc-dev am: 6e9ee1c78f am: 21f73b0d90 am: 4db9ae8cf1 am: f69e592fba
Change-Id: I8aa90ef1b6188aae96bf46b211c41950a6947f52
2020-04-27 05:34:05 +00:00
TreeHugger Robot
6e9ee1c78f Merge "Keeps the served view of the window when focus to the next window" into rvc-dev 2020-04-27 04:40:38 +00:00
Ming-Shin Lu
6743813471 Keeps the served view of the window when focus to the next window
CL[1] intends to reset served view and restart input state when focus to
the next window, which the main idea is try to make the lifecycle of the
input connection can more aligned with the window focus change.

However, this behavior change unexpectedly breaks Gboard
TranslatesUIExtention that will closeExtensionView when
onFinishInputView -> onDeactivate called, while launching language
selection dialog.

Remove the reset logic as the lifecycle of input connection still
needs to break down.

[1]: I8d4fff94ba9313b773bc27fcbd019cc88580d3e9

Fix: 152373385
Test: To make sure not break Bug 148489857 and Bug 148788569, following
auto / manual test to verify:
 - Auto: atest FocusHandlingTest#testKeyboardStateAfterImeFocusableFlagChanged
 - Manual:
    1) Build / install EditTextVariations
    2) Select menu -> Direct-Reply, make sure Notification comes up.
    3) Tap EditText on Notification, verify soft-keyboard is visible.

Change-Id: If20cdb43ecd013c330c5e16c73e9af972bd89f33
2020-04-27 03:22:52 +00:00
Robert Carr
b9cf275b9b BLAST: Two start-up optimizations
1. Avoid a seperate IPC querying in to system-server
   to initialize the mUseBLAST flag.
2. Avoid calling property_get_bool with each BufferQueue
   creation.

Instead we piggy-back both values inside addWindow return values.

Bug: 152501005
Test: Existing tests pass
Change-Id: If130560a8230f8d399cf7631264d551522939faa
2020-04-24 14:42:55 -07:00
Automerger Merge Worker
3e3e774b18 Merge "Merge "Add @TestApi to registerSystemAction and unregisterSystemAction" into rvc-dev am: 8ab42a27ce am: e5c438c6f6" into rvc-d1-dev-plus-aosp am: 9389a27ef4 am: c76e93862e
Change-Id: I5f04bc087106bd2ee82a4625f5cc35ce6aacc9a9
2020-04-24 20:57:24 +00:00
Sally Yuen
8ab42a27ce Merge "Add @TestApi to registerSystemAction and unregisterSystemAction" into rvc-dev 2020-04-24 20:12:16 +00:00
Taran Singh
8321a2a48d Add test for ImeInsetsSourceConsumer
Add test to verify that requestedVisibleAwaitingControl starts
animation. This is followup test for comment in commit
I958fc5747382109aa2f21bc1067a28746e7242d8

Bug: 154440912
Fix: 153577930
Test: atest ImeInsetsSourceConsumerTest
Change-Id: I08db27151605ac53b0575b08343b5a75dc2e5fc2
2020-04-24 11:37:30 -07:00
TYM Tsai
41447be309 Merge "Filter the content of the Bundles used as extras and styling APIs" into rvc-dev am: 4ddfdaf641 am: 5c913aeacc am: 6cce28ebbc am: 009fb7ec44
Change-Id: I4d317f36033a59baf9001f7017ffd3beffc20c2b
2020-04-24 09:49:21 +00:00
TYM Tsai
4ddfdaf641 Merge "Filter the content of the Bundles used as extras and styling APIs" into rvc-dev 2020-04-24 08:42:56 +00:00
Automerger Merge Worker
eef99da3b6 Merge "Merge "Update the description of getWaterfallInsets()" into rvc-dev am: b578ddde3e am: 9f4ea365f7" into rvc-d1-dev-plus-aosp am: 2579345da5 am: fe1851532e
Change-Id: Idec60bf8075bfc585db12bf566fcefe8c93ff3a4
2020-04-24 06:50:41 +00:00
Shawn Lin
b578ddde3e Merge "Update the description of getWaterfallInsets()" into rvc-dev 2020-04-24 05:56:04 +00:00
Jason Hsu
005f2acff1 Merge changes from topic "rhedjao_a11y_button_rollback" into rvc-dev am: ea2d4bf1fd am: a574c632c5 am: e56a98a820 am: bd5a346909
Change-Id: I64079947e3cf089b6555a9d24aafde794ef380f0
2020-04-24 03:31:45 +00:00
Jason Hsu
ea2d4bf1fd Merge changes from topic "rhedjao_a11y_button_rollback" into rvc-dev
* changes:
  Rollback chooser menu to version Q behavior for accessibility button (2/n).
  Rollback chooser menu to version Q behavior for accessibility button (1/n).
2020-04-24 03:07:39 +00:00
Evan Rosky
cff7ebb93d Connect systemwindow root with accessibility
This sets the most-recently created view on a shellroot
to be used as the "accessibility" window. This allows
each shellroot to have 1 window that accessibility sees.

Bug: 152368950
Test: atest AccessibilityWindowQueryTest#testWindowDockAndUndock_dividerWindowAppearsAndDisappears
Change-Id: Ice2820e11544ccdf7a3e600f918eac0ffb506548
2020-04-23 19:01:53 -07:00
sallyyuen
8bc474b8df Add @TestApi to registerSystemAction and unregisterSystemAction
@SystemApi requires @hide, so @TestApi is needed for these to
be visible to CTS testing

Test: methods visible to CTS test
Bug: 152052560
Change-Id: Icd7f82f3859a1deccd41d2279d8f9722a42df957
2020-04-23 09:40:18 -07:00
Peter_Liang
0589ab0ae3 Rollback chooser menu to version Q behavior for accessibility button (2/n).
Allow separate Activities to handle the multiple-target case for the hardware and software shortcuts. Migrate from an extra to an explicit class so the Intent dispatch will launch the correct Activity for the particular shortcut.

Bug: 151294664
Test: manual test
Change-Id: I54bb1d3ab91e2757c465e8763786d0234f6d4ea8
2020-04-23 16:25:17 +00:00
Charles Chen
1d27e76e9b Merge "Limit number of window context without any window" into rvc-dev am: 1e52a093ae am: 20f72281dd am: 65ca556487 am: 6237d88b9b
Change-Id: I3c2f662692c355cdce63528fc4cb4801e001f40b
2020-04-23 04:30:04 +00:00
Charles Chen
1e52a093ae Merge "Limit number of window context without any window" into rvc-dev 2020-04-23 03:34:37 +00:00
Jacky Kao
0785cfdd1f Merge "Makes AccessibilityNodeInfo#getSourceNodeId as test API" into rvc-dev am: f6f8deea32 am: b6ce1cf0d6 am: 0272eec6ed am: 48ff10d5ba
Change-Id: I8ac059b7bcd8b1bb369339b093cb771c03eb6be9
2020-04-23 02:00:31 +00:00
Jacky Kao
f6f8deea32 Merge "Makes AccessibilityNodeInfo#getSourceNodeId as test API" into rvc-dev 2020-04-23 01:08:46 +00:00
TreeHugger Robot
906c2a880c Merge "Remove old versions of attachAndQueBuffer" 2020-04-22 23:03:49 +00:00
Tiger Huang
df2459bfdd Merge "Do not dispatch leashes if they are not ready" into rvc-dev am: 75485cf52e am: 5c893d3662 am: 7f6e35fd02 am: a8bc95a33e
Change-Id: I27110601ee27008971b9fe95578b16e61f409af3
2020-04-22 20:08:04 +00:00
Tiger Huang
75485cf52e Merge "Do not dispatch leashes if they are not ready" into rvc-dev 2020-04-22 19:25:24 +00:00
Tiger Huang
e480e5f49c Do not dispatch leashes if they are not ready
The previous solution used a different transaction from the one used in
SeamlessRotator#finish. So the transaction might be applied in an
unexpected order between here and there when the target frame number is
reached.

This CL reverted the previous solution. Instead, we don't dispatch the
leash if it is not ready. For the client, it won't play the animation
until obtaining the leash.

Fix: 154195854
Test: Rotate device to change the orientation in Camera, and see if
      navigation bar stays visible.
Test: Check if transient bar can be shown/hidden/aborted as expected.
Test: Make sure b/153104643 stay fixed.
Test: atest InsetsPolicyTest
Change-Id: I29f80f1c77615b0a3cde38df265220f48d66f117
2020-04-22 20:23:18 +08:00
Charles Chen
2622d3ef7e Limit number of window context without any window
This change is to prevent misuse of window context from app
and leads to performance drop on system by limit the numer of window
context an app can use. Code snippet below is a sample to cause
this issue:
```
Rect getBounds() {
    Context windowContext = context.createWindowContext(...);
    return windowContext.getSystemService(WindowManager.class)
            .getCuttentWindowMetrics().getBounds()
}
```
This method could be invoked dozens of times and produce dozens of window
tokens. It would slow down the speed of window traversalling. These
token won't be removed until system server has been GC'd.

Test: atest WindowContextTests WindowContextPolicyTests
fixes: 152934797
Bug: 153369119

Change-Id: I927e85a45c05c4d90b51a624ea408ff3a3ffce93
2020-04-22 18:16:56 +08:00