Commit Graph

16946 Commits

Author SHA1 Message Date
Ben Lin
1e398917c4 Merge "PiP: Move enter-PiP on-pause logic." into sc-v2-dev am: 5643e20db3 am: a12047dc90
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14754525

Change-Id: Id5a40c0712f75e974aab0e15168d39b67e228e5d
2021-06-17 22:00:13 +00:00
Ben Lin
5643e20db3 Merge "PiP: Move enter-PiP on-pause logic." into sc-v2-dev 2021-06-17 21:50:11 +00:00
Yunfan Chen
79f50e814a Merge "Layout status/nav bar and decor window as normal window" into sc-v2-dev am: 56aad85b0d am: 5cc5855633
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14732017

Change-Id: Ic246de91f4357d115fb3481a139505c41437bad4
2021-06-17 02:22:24 +00:00
Yunfan Chen
56aad85b0d Merge "Layout status/nav bar and decor window as normal window" into sc-v2-dev 2021-06-17 01:46:00 +00:00
Ben Lin
6a55435011 PiP: Move enter-PiP on-pause logic.
Previously, we rely on #makeInvisible in other situations as the last
place to enter PIP before activity gets put to stopped (e.g. ARC++).
However with Shell transitions, #makeInvisible is now immediately called
as user starts the transition into Recents, which would cause app to
enter PIP right away. Thus, removing this part of the code, and instead
we will wait until the Recents transition is finished and try to pause
the app with userLeaveHint before visibility is committed.

Also, when shell transition is enabled, make an explicit transition when
dmissing PIP to properly commit the necessary window container changes
to WM. The tranition will just have no animation.

Bug: 165793917
Test: Enable Shell transition, enter PIP via gesture (non-auto enter
case)
Test: Enable Shell transition, dismiss PIP via dismiss bubble

Change-Id: Ic2c8691f5a1f359b822b1874b16a327bc689f34d
2021-06-16 13:32:28 -07:00
TreeHugger Robot
2760cb2d3c Merge "ContentCaptureEvent: Log composing and selection indices" into sc-dev am: 8f74aa34ee am: 805862b48d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14960922

Change-Id: Id4ccc3a68d131678a6065ed210bacdb8e7c3171e
2021-06-16 09:18:48 +00:00
TreeHugger Robot
86428a3591 Merge "ContentCaptureEvent: Log composing and selection indices" into sc-dev am: 8f74aa34ee
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14960922

Change-Id: I68a7abf9d4da0dbfb1d1276814f65e7971fe6586
2021-06-16 09:10:09 +00:00
TreeHugger Robot
8f74aa34ee Merge "ContentCaptureEvent: Log composing and selection indices" into sc-dev 2021-06-16 08:46:41 +00:00
TreeHugger Robot
5b2e3c2538 Merge "ContentCapture: DEBUG flag to log raw text" into sc-dev am: 949b4d2940 am: b8c160bd0f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14982209

Change-Id: Ibb5a962014606950d377c4c5b1be69521559acd9
2021-06-16 06:47:50 +00:00
TreeHugger Robot
388d8a3657 Merge "ContentCapture: DEBUG flag to log raw text" into sc-dev am: 949b4d2940
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14982209

Change-Id: I1ee7c180158628fac9711a795ab04a78fbe33886
2021-06-16 06:34:52 +00:00
TreeHugger Robot
949b4d2940 Merge "ContentCapture: DEBUG flag to log raw text" into sc-dev 2021-06-16 06:32:35 +00:00
Ahaan Ugale
d224da0ed4 ContentCaptureEvent: Log composing and selection indices
Bug: 184311217
Test: manual
Change-Id: I808021473fe55bf2f0676c005bc0c077146a6785
2021-06-15 22:21:26 -07:00
TreeHugger Robot
7b36f78bf6 Merge "Increase initial StringBuffer capacity in View.toString." 2021-06-15 22:17:56 +00:00
Siarhei Vishniakou
c664495196 Merge "Remove FLAG_INPUTFILTER_TRUSTED in MotionEventInjector" into sc-dev am: 5d552869af am: b637d6f106
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14676739

Change-Id: Ia3010b90e45eb9f2f19e76b0b6fa3e8c237b55c5
2021-06-15 22:11:20 +00:00
Siarhei Vishniakou
c3fb5dcd53 Merge "Remove FLAG_INPUTFILTER_TRUSTED in MotionEventInjector" into sc-dev am: 5d552869af
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14676739

Change-Id: I6ad42551ed0bbd48270fb3386f717727b3374779
2021-06-15 21:55:49 +00:00
Siarhei Vishniakou
5d552869af Merge "Remove FLAG_INPUTFILTER_TRUSTED in MotionEventInjector" into sc-dev 2021-06-15 21:50:35 +00:00
TreeHugger Robot
78bb87d1c6 Merge "Make inline suggestions tooltip is not magnified" into sc-dev am: cac7ab9c5c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14514105

Change-Id: I690b8b91aed71839ce7b19c32e7de209cb08a863
2021-06-15 21:36:45 +00:00
TreeHugger Robot
7c73cc1f6e Merge "Make inline suggestions tooltip is not magnified" into sc-dev am: cac7ab9c5c am: 40c5c91871
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14514105

Change-Id: Ic5c75dcc71639e01c919e66cad134d339699b8ba
2021-06-15 21:33:54 +00:00
TreeHugger Robot
cac7ab9c5c Merge "Make inline suggestions tooltip is not magnified" into sc-dev 2021-06-15 21:22:09 +00:00
TreeHugger Robot
3343e5077b Merge "Make some NoCopySpans can pass to ContentCaptureService" into sc-dev am: 7063bae045 am: 1fdb34202f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14891918

Change-Id: I597a5107b3e71d25b7680e8cfd7f580729029b26
2021-06-15 19:14:33 +00:00
TreeHugger Robot
f290a87c1a Merge "Make some NoCopySpans can pass to ContentCaptureService" into sc-dev am: 7063bae045
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14891918

Change-Id: I5dc35c9b31952db6f44e21cb9166e83630aa8644
2021-06-15 18:53:57 +00:00
TYM Tsai
b8fe7ce3bb Make some NoCopySpans can pass to ContentCaptureService
The selection and composing spans are not parcelable. This patch makes
Content Capture can pass those metadata to the service.

Bug: 184311217
Test: atest CtsContentCaptureServiceTestCases
Test: atest FrameworksCoreTests:ContentCaptureEventTest
Change-Id: I455ee61998bfb19476f84c69b1a671113b6b6a98
2021-06-16 01:22:39 +08:00
Ahaan Ugale
0f163f5557 ContentCapture: DEBUG flag to log raw text
Bug: 184311217
Test: manual
Change-Id: I9a60bcf95574583c14f5962a3dde603abea85498
2021-06-15 09:05:16 -07:00
Huihong Luo
6c45653f0f Merge "Fix NullPointerException on ThreadedRenderer" into sc-dev am: eee7cc8764 am: 2d355922ca
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14947021

Change-Id: I4aace23bee4258ce44837a6594ce517f6f251535
2021-06-14 16:52:14 +00:00
Huihong Luo
d74e376eae Merge "Fix NullPointerException on ThreadedRenderer" into sc-dev am: eee7cc8764
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14947021

Change-Id: I5a068f8c8c87cd299272ecf63f0d4439dc28e488
2021-06-14 16:51:45 +00:00
Huihong Luo
eee7cc8764 Merge "Fix NullPointerException on ThreadedRenderer" into sc-dev 2021-06-14 16:48:31 +00:00
Yunfan Chen
fce2e99c68 Layout status/nav bar and decor window as normal window
Use the general layout process for system bar windows. The hard-coded
logic of the bar position is also disabled by the patch. Such that, the
system UI will have the ability to layout the window freely.

The bars sometimes need to be layout with new rotation before the actual
rotation when we simulate the display with fixed layout. To support
that, new layout params for orientation is introduced to the layout params.

The bar may need to provide a different insets frame in gesture
navigation mode. That is for the IME to draw the hide button. Introduced
a new param called providedInternalInsets to resolve that usage.

The new flexible layout is protected by the flag
persist.debug.flexible_insets.

Bug: 161689946
Bug: 169329927
Test: DisplayPolicyTests InsetsSourceProviderTest
      InsetsStateControllerTest
Change-Id: If8ec79b3cb3b989eed578c44e8749b13fd2e8592
2021-06-14 21:06:48 +09:00
TreeHugger Robot
5c85d4f044 Merge "Clear the ViewTranslationResponse on finishing UiTranslation." into sc-dev am: 2828678bd4 am: fe2cee843f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14922772

Change-Id: I547fe45870b4239d95e5a00d05e68479a21c4504
2021-06-14 01:38:52 +00:00
TreeHugger Robot
6cda59d41b Merge "Clear the ViewTranslationResponse on finishing UiTranslation." into sc-dev am: 2828678bd4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14922772

Change-Id: I5bf07de96eda6f2a16e003714c0f17b072515ea7
2021-06-14 01:26:52 +00:00
TreeHugger Robot
2828678bd4 Merge "Clear the ViewTranslationResponse on finishing UiTranslation." into sc-dev 2021-06-14 01:12:59 +00:00
John Reck
c65ea76a62 Merge "Improve picture capture debug path" into sc-dev am: b99e72f722 am: c44920c3cd
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14928133

Change-Id: I5cf8350049c3e8d102cb385f0a02401c0d5eab1b
2021-06-11 18:39:11 +00:00
John Reck
25d806cb95 Merge "Improve picture capture debug path" into sc-dev am: b99e72f722
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14928133

Change-Id: I74a78fd84f96fac075150016af356906a612fcf6
2021-06-11 18:29:46 +00:00
Huihong Luo
1c3d52c130 Fix NullPointerException on ThreadedRenderer
The variable, mAttachInfo.mThreadedRenderer, might be null.

Bug: 188614814
Test: run x86_64 cts test: CtsInputMethodTestCases
Change-Id: I5c441d8948dd357992ad5ef94d03deff547baa37
2021-06-11 11:20:32 -07:00
John Reck
760051854e Improve picture capture debug path
* Fixes hardware bitmap capture
* Fixes mutable bitmap capture (no flickering)
* Adds basic single-frame LRU cache to avoid
  repeated readbacks of GPU resources
* Does up-front readback of GPU resources
* Moves serialization off RenderThread again thanks
  to up-front readback avoiding needing GPU access
  off-thread
* Reduces RAM usage & improves performance by serializing
  directly to output stream instead of first copying to
  a byte[]

Bug: 174223722
Test: PictureCaptureDemo mirrors the content
Change-Id: If7ec208b61d5b917e82087cc312880fc5a38c943
2021-06-11 01:52:14 +00:00
Tiger Huang
0667ac5b91 Merge "Defer dispatching insets to app if its window frame will be changed soon" into sc-dev am: 50ae7cbf1b am: d0c6024002
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14881021

Change-Id: Ie99d5ce746f009423f0e84c375dc801f34fb8b6d
2021-06-10 08:26:00 +00:00
Tiger Huang
be91de455b Merge "Defer dispatching insets to app if its window frame will be changed soon" into sc-dev am: 50ae7cbf1b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14881021

Change-Id: I7377340b7fedc22df682ffbd9675fc5109a506a3
2021-06-10 08:13:42 +00:00
Tiger Huang
50ae7cbf1b Merge "Defer dispatching insets to app if its window frame will be changed soon" into sc-dev 2021-06-10 07:55:53 +00:00
Ahaan Ugale
f922300a2d Clear the ViewTranslationResponse on finishing UiTranslation.
Stored state should be cleared here.

This fixes a bug where the views cannot be re-translated after
UiTranslationManager#finishTranslation was called. Some of the state was
cleared, so the translations cannot be re-shown. And that state cannot
be recreated because we find the same ViewTranslationResponse stored and
do not recreate the other state.

Fix: 189892928
Test: manual - translate an app, go to the home screen (triggers
 finish), go back to the app and re-translate
Test: atest CtsTranslationTestCases
Change-Id: Ic81fbce7ee09eb72352071c8bdd94a2731826009
2021-06-09 13:53:38 -07:00
TreeHugger Robot
6f386fd1af Merge "Remove tracing for notifyContentCapture" into sc-dev am: 789fe38968 am: 38c190df2b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14904360

Change-Id: I9fb66e57eef3d99a514d0f316a6626c81c6140cc
2021-06-09 19:36:20 +00:00
TreeHugger Robot
49cfb97ac0 Merge "Remove tracing for notifyContentCapture" into sc-dev am: 789fe38968
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14904360

Change-Id: Ide3b5000b8dd695adda3ef84271de5cc11b713ab
2021-06-09 19:30:27 +00:00
TreeHugger Robot
789fe38968 Merge "Remove tracing for notifyContentCapture" into sc-dev 2021-06-09 19:14:05 +00:00
TYM Tsai
0a496a2aa0 Make inline suggestions tooltip is not magnified
Because the tooltip is part of suggestions on keyboard, it should be the
same as keyboard that is not magnified by the accessibility magnifier
when the magnifier is full screen mode.

Bug: 183462449
Test: Manual
Test: atest CtsAutoFillServiceTestCases
Change-Id: I3cfd84357b556a85c2788776d3966cf94d4a981d
2021-06-10 02:16:19 +08:00
TreeHugger Robot
b2d0f8e95e Merge "Make ContentCapture event contains parcelable span" into sc-dev am: 3009984d65 am: 15b3bbcfc3
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14819344

Change-Id: Ie4e86f8acd317a407bd902a1288f01b3cf4faa80
2021-06-09 17:21:28 +00:00
Mark Renouf
e23d604095 ScrollCaptureTarget: enforce argument nullability in ctor am: 886b1a3d7c am: b65f47c918
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14846764

Change-Id: I689d6b806aa14d8004f4c79332e8a955cc43af5b
2021-06-09 17:21:10 +00:00
TreeHugger Robot
17dddb1b96 Merge "Make ContentCapture event contains parcelable span" into sc-dev am: 3009984d65
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14819344

Change-Id: I4693e6fdb51ba4b01e1de837df3be9dec7f5d08e
2021-06-09 17:07:03 +00:00
Mark Renouf
78060a53a2 ScrollCaptureTarget: enforce argument nullability in ctor am: 886b1a3d7c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14846764

Change-Id: I1c75e3d83f41733ea50a2d3dc73e7afc0b2df3c8
2021-06-09 17:06:56 +00:00
TreeHugger Robot
3009984d65 Merge "Make ContentCapture event contains parcelable span" into sc-dev 2021-06-09 16:48:55 +00:00
Mark Renouf
886b1a3d7c ScrollCaptureTarget: enforce argument nullability in ctor
Bug: 180419562
Test: atest ScrollCaptureTargetTest
Change-Id: I390269c8cfc0ce57c5cf9b58ad0cbf75a0281b00
2021-06-09 16:48:26 +00:00
TYM Tsai
b8fc743699 Make ContentCapture event contains parcelable span
The spans were removed by ag/13819626. Adds them back into the
ContentCaptureEvent. And removes unnecessary Map data because we
can get it via travel events. The total of events is not large.

Bug: 190035037
Bug: 184311217
Test: atest CtsContentCaptureServiceTestCases
Test: atest FrameworksCoreTests:ContentCaptureEventTest
Change-Id: I5fa1f7a6b51fd050a63731543cca98972c294b22
2021-06-09 16:48:23 +00:00
Tiger Huang
7be2a4c964 Defer dispatching insets to app if its window frame will be changed soon
If the frames of insets source window and the frame of an app window
are changed in the same layout pass, we should dispatch the insets
calculated from the new insets source frames and the new app window
frame. So when the app frame is not up-to-date, we defer dispatching
insets to the app.

Fix: 160732586
Test: Add logs to check if we dispatch the correct insets to apps while
      rotating the display.
Change-Id: Ic9e71d8eabde51067b740b35404ae7c9b68228d7
2021-06-09 15:52:39 +08:00