Commit Graph

13172 Commits

Author SHA1 Message Date
Winson Chung
df69ae467a Merge "Modify deferred recents animation cancel to work without screenshot" into qt-r1-dev am: 48e3cfc06a am: 932a656359
am: 71626be681

Change-Id: Ie5636139863163d42788314c0e8ca0c946a80ae1
2019-07-24 00:33:54 -07:00
Winson Chung
932a656359 Merge "Modify deferred recents animation cancel to work without screenshot" into qt-r1-dev
am: 48e3cfc06a

Change-Id: Id491b61fc851779bd398c5113a306ce1c89181dc
2019-07-23 22:24:38 -07:00
Winson Chung
7a545ae9cc Modify deferred recents animation cancel to work without screenshot
- Allow the recents animation runner to request deferring a cancel from
  stack order change until the next app transition start without using
  a screenshot. This allows launcher to set this state, then start an
  activity without a flash due to the animation not finishing immediately
- Always prepare a transition when using the deferred cancel to ensure
  an app transition callback
- Handle app transition canceled as well (if canceled, we continue to
  cancel recents the animation with/without the screenshot as requested)
- Remove internal lock and use the global WM lock when setting the defer
  cancel state
- Renamed a few methods to clarify the deferred cancel flow

Bug: 137196872
Test: atest FrameworksServicesTests:RecentsAnimationControllerTest
Test: atest WmTests:RecentsAnimationTest
Change-Id: Ie8f6f60b6bf6777e36f24749b30f90c8c26ee848
2019-07-23 15:50:33 -07:00
Vishnu Nair
3b037f7250 Consolidate ViewRootImpl callbacks for SurfaceView
Use ViewRootImpl surface created and destroyed callbacks to set window stopped state
and update the SurfaceView visibility accordingly.

Bug: 132205507
Test: go/wm-smoke
Change-Id: Ie43e3cc81729a153e36fffbefe242d78d8e38222
2019-07-22 12:56:54 -07:00
Vishnu Nair
49230c4277 Add surface changed callbacks to ViewRootImpl
Allow SurfaceView to be notified when the ViewRootImpl surface changes, is created or
destroyed. The callbacks include a SurfaceControl Transaction object which can be used to
synchronize SurfaceControl changes by the system.

In particular, the transaction will be used to update the relative z order of the SurfaceView
surface when the ViewRootImpl surface changes. WMS is responsible for providing ViewRootImpl a
new surface as well as reparenting its children (SurfaceViews). The transaction will be applied by
the service when it is ready to show the new surface, synchronizing the reparenting with the
relative z update.

Bug: 132205507
Test: go/wm-smoke
Change-Id: Ie5aed430d09cc6d3a0a99f618094b3a50dbaa5cc
2019-07-22 12:56:54 -07:00
TreeHugger Robot
faaa4e62b9 Merge "IWindowSession.Default is not available" 2019-07-22 12:10:25 +00:00
Jackal Guo
73715ca6c3 Merge "Add new APIs to support RegionInScreen in A11yWindowInfo" 2019-07-17 06:43:45 +00:00
Jackal Guo
f382371d77 Add new APIs to support RegionInScreen in A11yWindowInfo
To support non-rectangular visible area for windows, add new APIs
about RegionInScreen in A11yWindowInfo to represent the actual
interact-able area of a window.

Bug: 132146558
Test: a11y CTS & unit tests
Change-Id: I86bb6bc8c567e09f01a3f853a3cffd896ce934c8
2019-07-17 10:57:09 +08:00
Adrian Roos
66e52c79cd Merge "GestureNav: make reportSystemGestureExclusionChanged oneway" into qt-dev am: d4a50e6e72
am: 7c77af6371

Change-Id: I3de6ae14483976dc659fb5aadbedae2f2f8dc00c
2019-07-16 15:09:17 -07:00
Adrian Roos
7c77af6371 Merge "GestureNav: make reportSystemGestureExclusionChanged oneway" into qt-dev
am: d4a50e6e72

Change-Id: I9f837989727c263517aa0d2f3dfd47a830f6170c
2019-07-16 15:00:35 -07:00
Adrian Roos
e6911497de GestureNav: make reportSystemGestureExclusionChanged oneway
When the WindowManager lock is contended, reportSystemGestureExclusionChanged can cause
jank. Making it oneway avoids this.

Fixes: 137650591
Test: make droid
Change-Id: I5d96b7e2225745b146014ad11cafaf0ad9a1b734
Merged-In: I5d96b7e2225745b146014ad11cafaf0ad9a1b734
2019-07-16 20:29:03 +00:00
Adrian Roos
2dccd145d3 GestureNav: make reportSystemGestureExclusionChanged oneway
When the WindowManager lock is contended, reportSystemGestureExclusionChanged can cause
jank. Making it oneway avoids this.

Fixes: 137650591
Test: make droid
Change-Id: I5d96b7e2225745b146014ad11cafaf0ad9a1b734
2019-07-16 17:58:15 +00:00
Tarandeep Singh
eafd4dae94 Merge "Make MULTI_CLIEN_IME_ENABLED non-testable." 2019-07-16 17:48:51 +00:00
Issei Suzuki
6b5f5e97e8 Refined the logic to detect the location of DisplayCutout.
Bug: 117199965
Test: atest DisplayCutoutTest
Change-Id: I943922ff6e2866c783b88ce3b2c9bca494d688d7
2019-07-15 15:44:01 +02:00
Jiyong Park
624b393ef3 IWindowSession.Default is not available
<Iface>.Default class was automatically generated, but a change in the
AIDL compiler is scheduled to generate the class only when the AIDL file
is compiled with '-version' option, because the default class is only
useful for the versioned AIDL case.

Stop using IWindowSession.Default since it will be removed. Instead
implement IWindowSession directly.

Test: build
Change-Id: I4551ddcbd794d0d99dc0952bbd6414a2112a5ea2
2019-07-11 20:06:34 +09:00
Rhed Jao
882145e7e0 Improve A11yNodeInfo visibility for magnification
Returns visible if device enables magnification and node is visible
but outside of magnified area.

Bug: 79162853
Bug: 79531479
Test: atest AccessibilityMagnificationTest
Change-Id: I481bd5c3d73d01c0cd8b3e0ebd7a1584c9ae7064
2019-07-11 16:51:39 +08:00
Tarandeep Singh
db6c7815b7 Make MULTI_CLIEN_IME_ENABLED non-testable.
This mechanically reverts making MULTI_CLIEN_IME_ENABLED
testable originally introduced in [1].
CTS tests can check for FEATURE_INPUT_METHODS instead.
FEATURE_INPUT_METHODS is false for Android auto and true for
devices that support installable IMEs.

[1] Id7b4dceb2dbfaf3d7ed1084957dd14b04cad0cdf

Bug: 137203665
Test: Manually built and verified that it builds.
Change-Id: I6e430458dd05dec363f67b62416d424c395f2d5a
2019-07-10 13:28:38 -07:00
Tarandeep Singh
ff0d28905f Merge "Remove PER_PROFILE_IME_ENABLED property" 2019-07-10 18:06:39 +00:00
Tarandeep Singh
cf5ff82fca Remove PER_PROFILE_IME_ENABLED property
PER_PROFILE_IME_ENABLED is default enabled in Q. We no longer need this
property.

Bug: 135775619
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Change-Id: Ia957118fabc2dd794cb4f5018692b8548b85233a
2019-07-09 14:53:48 -07:00
TreeHugger Robot
dc8c71b1df Merge "TextClassifier cross-user vulnerability in direct-reply" 2019-07-09 17:55:04 +00:00
TreeHugger Robot
6a727cafa6 Merge "Fix missing version number in logs from webview" 2019-07-09 15:19:41 +00:00
Abodunrinwa Toki
e8492693c2 TextClassifier cross-user vulnerability in direct-reply
Sys UI runs on user 0. This can lead to the TextClassifier (TC)
running for the wrong user. Consequencies are user A can launch apps
in user B via the TC's predicted actions and selected text being
unintentionally shared from user A to an app running in user B.

This fix ensures that the correct user id is passed and verified for
every TC request going across process boundaries (i.e. via SystemTC).
- Sys UI sets the appropriate user id in the TextView
- TextClassificationManager (TCM) system service is constructed using
  a context generated from this user id
- SystemTC sets this user id before querying the TCMService
- TCMService validates the user id before forwarding the request to
  the TCService belonging to that user id.

Bug: 136483597
Test: atest android.view.textclassifier
      atest android.widget.TextViewActivityTest
      (manual) Verified according to steps in bug 123232892
Change-Id: I2fdffd8eb4221782cb1f34d2ddbe41dd3d36595c
2019-07-08 15:16:19 +01:00
Tony Mak
b393eeabde Fix missing version number in logs from webview
fromIndex is inclusive, so it should be startIndex +1.

This bug is fixed in our new logging APIs, but to those who
is still using the old pipeline, e.g: webview, will hit the issue.

Fixes: 136805228
Test: Enable verbose logging, try to select something in webview,
observe that the version number is logged.
Test: atest SmartSelectionEventTrackerTest

Change-Id: I7e8212d9be9684b9988634cf30043765dd8afe38
2019-07-05 17:06:14 +01:00
Issei Suzuki
4dd6a45d3c Merge "Support alpha value in SurfaceView." 2019-07-04 12:25:53 +00:00
TreeHugger Robot
693884a663 Merge "Add trackingBug to APIs used by chromium vebview." 2019-07-04 09:58:45 +00:00
Issei Suzuki
006b71f401 Support alpha value in SurfaceView.
For backward compatibility, SurfaceView ignores alpha value by
default. In order to reflect alpha value set on the SurfaceView
to its underlying surface, setUseAlpha() needs to be called.

Translucent alpha only works when the surface is placed z-above.
Otherwise only fully opaque and transparent status are supported.

Bug: 130442248
Test: Manual, use BubblesTest app and checks if alpha is set.
Change-Id: I86847de59109b2adf12a2c7c50c988c2cbcf0450
2019-07-04 09:49:23 +02:00
Qasid Sadiq
aabd50e0a4 Merge "Populate scrollX and scrollY on AccessibilityEvents." 2019-07-03 23:17:52 +00:00
Issei Suzuki
60557b5bf5 Clean up SurfaceView.
Bug: 136538998
Test: no-op refactoring CL. Existing unit tests still pass.
Change-Id: Idd6c5871ed34880a053f3a43ab4f7aa3a466b548
2019-07-03 20:04:48 +02:00
TreeHugger Robot
08c51ea668 Merge "Removed unused variable from ThreadedRenderer" 2019-07-03 16:56:03 +00:00
Mathew Inwood
5ca23f6a5a Add trackingBug to APIs used by chromium vebview.
Bug: 136637107
Test: m
Change-Id: I5b7612325d8b7e2578e71a75f60790039bc28eea
2019-07-03 12:20:45 +01:00
TreeHugger Robot
4b235cb04a Merge "Clean up SurfaceView" 2019-07-03 09:21:41 +00:00
Issei Suzuki
f78b5e2e44 Removed unused variable from ThreadedRenderer
Bug: 136616503
Test: refactoring, check if existing tests pass
Change-Id: I627832b2e8f964dbabbf95788279e437c4347adf
2019-07-03 10:23:37 +02:00
Issei Suzuki
f0412592db Clean up SurfaceView
Bug: 136538998
Test: no-op refactoring CL. Existing unit tests still pass.
Change-Id: Ibd0310a87ed38aa48215be9cba54f1c7a2a8a9fa
2019-07-02 12:33:13 +02:00
John Reck
5e56d3f12b Merge "Switch to import for CtsUiRenderingTestCases" 2019-07-01 15:59:33 +00:00
Issei Suzuki
9e6679b040 Merge "Extend ViewRootImpl to support multiple FrameDrawingCallback" 2019-07-01 12:47:06 +00:00
Peiyong Lin
472eac2a3c Merge "Attach color space information when attach and queue buffer." into qt-r1-dev am: 964fcdbebd
am: 7537aeeb9f

Change-Id: I245e704a1d794ddb56892a97c74bf11effe0c3a1
2019-06-28 15:41:25 -07:00
Peiyong Lin
7537aeeb9f Merge "Attach color space information when attach and queue buffer." into qt-r1-dev
am: 964fcdbebd

Change-Id: I37376be3cdf0a8c72111c6de257eda4274f406c2
2019-06-28 14:35:34 -07:00
Mathew Inwood
b2f6f30c19 Merge "Restore some greylist entries." into qt-dev am: f4535c8d51 am: cd82f9adff
am: 7a4d871174

Change-Id: If3c3de3ec24226ec6ea10603ca246487ac40bfb4
2019-06-28 13:42:26 -07:00
Mathew Inwood
7a4d871174 Merge "Restore some greylist entries." into qt-dev am: f4535c8d51
am: cd82f9adff

Change-Id: Iff29bca8243e0c5e0e7ec30cd8b4a3f95c43ac82
2019-06-28 13:30:26 -07:00
Mathew Inwood
cd82f9adff Merge "Restore some greylist entries." into qt-dev
am: f4535c8d51

Change-Id: I3851fed60bedab9748f2d6d53f342f2605ecf78b
2019-06-28 13:18:30 -07:00
Mathew Inwood
f405e83cdc Merge "Restore some greylist entries." into qt-dev
am: f4535c8d51

Change-Id: I9349026a5f99cb2ebac1d9fadd3c716e8a06aaa3
2019-06-28 13:18:28 -07:00
Issei Suzuki
935935660c Extend ViewRootImpl to support multiple FrameDrawingCallback
Bug: 136150954
Test: WIP
Change-Id: I690005fece924c38a5269cb35309061d0ccb6f1e
2019-06-28 15:48:17 +02:00
Mathew Inwood
a5531fa161 Restore some greylist entries.
In Q, these APIs were either:
- removed from the greylist entirely without good reason
- Moved to the restricted greylist without any public alternative
  information added

So they are being moved back to the greylist for Q.

Test: Treehugger
Bug: 136102585
Change-Id: Ie3dd15c8e17d530d853473a013717e6175383080
2019-06-28 09:23:06 +00:00
Rob Carr
1e32e5f4a1 Merge "Enable views to be placed in windowless surfaces." 2019-06-27 19:43:31 +00:00
Felix
2b1c378f0c Merge "PhoneWindowManager/KeyEvent: Camera key as WakeKey" am: dec76b8a40 am: 1841f6af1d am: de67a21c84
am: 727d193d5d

Change-Id: I418a5275d5ff6148eb5405589a1f89d3d2fa3f4e
2019-06-27 10:34:25 -07:00
John Reck
db7d1df4fc Switch to import for CtsUiRenderingTestCases
Centralizes option management

Test: this
Change-Id: I80bcaec765e1ed2bf0bdbe370548157690367ec6
2019-06-27 10:32:27 -07:00
Peiyong Lin
964fcdbebd Merge "Attach color space information when attach and queue buffer." into qt-r1-dev 2019-06-27 16:14:02 +00:00
Robert Carr
9d431e1cc8 Enable views to be placed in windowless surfaces.
For purposes of parcelling SurfaceControl to embed view hierarchies across
processes. We also want these Surfaces to receive input, but we can't
let the clients call setInputWindowInfo directly (or we could have issues
with clients stealing focus, etc...) and so we provide a method
blessInputSurface which has the WM configure a surface for input with
a minimal and safe set of parameters.

Test: WindowlessWmTests
Bug: 111373437
Bug: 134365580
Change-Id: I45fde62ba9b810e783d62c4dd5442abd038734d5
2019-06-27 15:14:45 +01:00
Winson Chung
6ff63bdf73 Merge "Catch all exceptions in onFrameDraw" into qt-dev am: cff24b878d am: abe1a94072
am: 056fd40726

Change-Id: Icd452fb2132ffd98fe65ee5951f727e41a37f40b
2019-06-26 18:35:14 -07:00
Peiyong Lin
ccc06b6f51 Attach color space information when attach and queue buffer.
Currently when calling attachAndQueueBuffer, the color space information is
lost. This results in color shift if the color space doesn't match the color
space of the surface.

BUG: b/135002842, b/131928312
Test: boot. Manually verified on P19
Change-Id: I95ec73c24942f79197d25ee85f139b2aaf805677
2019-06-26 11:40:08 -07:00