Commit Graph

104112 Commits

Author SHA1 Message Date
Wenjie Zhou
ad24e49e2f Merge "mCallback defined in BringYourOwnSection should be an object instead of a reference." into rvc-dev 2020-05-15 02:06:30 +00:00
Wenjie Zhou
751c7c947a mCallback defined in BringYourOwnSection should be an object instead of a reference.
The referenced object could be destroyed and result in native crash when
mCallback is used.

Bug: 156536687
Test: manual test with registering a section from an app
Change-Id: Ie36c0e6e64be1246539f12999f037c24377686dd
2020-05-14 15:24:39 -07:00
TreeHugger Robot
5bf3f80f20 Merge "Add tracing for Inset animations" into rvc-dev 2020-05-14 22:16:23 +00:00
Cody Kesting
a611e762ad Merge "Create TestApi for simulating a Data Stall on ConnectivityService." into rvc-dev 2020-05-14 18:56:36 +00:00
Cody Kesting
3fdb1831a4 Merge "Set owner and administrator UIDs for test networks." into rvc-dev 2020-05-14 18:56:16 +00:00
Winson Chung
b159f28fce Merge "Skip parceling destroyed buffer" into rvc-dev 2020-05-14 17:32:08 +00:00
Tiger Huang
8fd8a538b8 Merge "Do not dispatch system UI visibility during traversal" into rvc-dev 2020-05-14 17:25:56 +00:00
Eino-Ville Talvala
1a66adcc56 Merge "Camera: Update documentation for rolling shutter skew" into rvc-dev 2020-05-14 16:49:42 +00:00
Matt Casey
d8aa60aa0d Merge "Allow WindowManager.TYPE_SCREENSHOT to be focusable" into rvc-dev 2020-05-14 16:37:58 +00:00
Winson Chung
5bd2a157c6 Skip parceling destroyed buffer
- Haven't been able to repro, but we shouldn't crash system server

Bug: 154382448
Test: Just adding a destroyed check
Change-Id: I412ab1703602723511a6bd3c598d34b6ade68db7
Merged-In: I412ab1703602723511a6bd3c598d34b6ade68db7
2020-05-14 16:05:07 +00:00
Jorim Jaggi
cb28ae6d17 Add tracing for Inset animations
So we can understand better what's going on.

Bug: 156367695
Test: Systrace
Change-Id: Ic9dc2c963f70a3bb787121d33476b84bd3dc5798
2020-05-14 17:46:32 +02:00
TreeHugger Robot
d99569f88a Merge "Revert "Finish input when the screen state is off"" into rvc-dev 2020-05-14 14:21:39 +00:00
TreeHugger Robot
0e58daf022 Merge "Pass window type to the InputWindowHandle of embedded window" into rvc-dev 2020-05-14 08:32:00 +00:00
arthurhung
d3f17d7df7 Pass window type to the InputWindowHandle of embedded window
A windowless SurfaceControl could grant input via
IWindowSession.grantInputChannel, but other window may receive the
obscured events because of the type value of input window is always 0.

The obscured or partially obscured flag indicates that the window
received this motion event is wholly or partially obscured by another
visible window above it.

We have to filter out the trusted overlap so the motion event could
properly dispatch to the view if it is a security sensitive application.

Bug: 156063505
Test: enter split window mode and check the motion event
Change-Id: I10f63ea131a70ee8cc7d5c4b3e5ca4e5f06fdbad
2020-05-14 11:59:23 +08:00
TreeHugger Robot
3a6ec37a71 Merge "Remove divider view when exiting splitscreen" into rvc-dev 2020-05-14 02:25:24 +00:00
Ming-Shin Lu
2c6e80be12 Revert "Finish input when the screen state is off"
This reverts commit 0df8812486.

The original CL is trying to reduce the dependency of PownerManager to
finish input when screen off by using display state.

However, it doesn't fully fix the original Bug 26851566 since we only
finish input connection but didn't callback onFinishInput callback for
IME client.

Also, for some scenarios, the window / view focus may not change
during screen turns off / on:
  - Focusing timing when disable keyguard, then quickly screen off / on.
  - Using P-sensor to turning screen off / on.

When the above scenario happens, makes input connection cannot re-start
and soft-keyboard can't be shown.
(The recovery is manually focus on next window or activity.)

As the above reason, we need to re-consider the lifecycle of
input connection, window / view focus when not only screen state but also
device inactive state when always-on-display.

Fix: 156045961
Fix: 154605805
Bug: 26851566
Bug: 156215187
Test: atest CtsInputMethodTestCases
Change-Id: If06daf71160aa44a4254ac125561974ecbdef4f2
2020-05-14 08:29:18 +08:00
TreeHugger Robot
bc9515e4b9 Merge "Change the timeout for integrity verification from 10 seconds to 30 seconds." into rvc-dev 2020-05-13 22:41:10 +00:00
TreeHugger Robot
4d857ccce5 Merge "Revert tab key behavior on multiline EditTexts." into rvc-dev 2020-05-13 22:30:21 +00:00
TreeHugger Robot
bff3812e82 Merge "SurfaceView: positionLost locking fix" into rvc-dev 2020-05-13 22:04:58 +00:00
TreeHugger Robot
730fb0d97d Merge "Fix inline suggestion ref counting to not over-count" into rvc-dev 2020-05-13 20:58:15 +00:00
TreeHugger Robot
897187dcfa Merge "Controls API - Flag controls support" into rvc-dev 2020-05-13 20:42:42 +00:00
Song Pan
74b5e72f17 Change the timeout for integrity verification from 10 seconds to 30 seconds.
Context: https://buganizer.corp.google.com/issues/154486093#comment24

Bug: 154486093
Test: N/A
Change-Id: I4fae3401ad7323acfa9cc520aac0cbb6bdbf6ada
2020-05-13 20:27:40 +01:00
Feng Cao
723ba2e82b Fix inline suggestion ref counting to not over-count
* Imagine this event sequence:
  1) the IME tries to re-attach an inline suggestion view to the
  window (e.g. because IME layout changes), it calls into the system
  server which causes recreating the backing view because it was
  destroyed earlier due to 0 ref-count (this happens under the hood
  without IME knowing it happens, so the view is still attached to
  the window).
  2) the IME receives a new inline suggestion pointing to the same
  backing view (perhaps due to filtering kicks in).
  3) the recreation from step 1 finishes, but now it will callback
  to the new inline suggestion, therefore the old view doesn't receive
  the new SurfacePackage. See RemoteInlineSuggestionUi for why.
  4) the view in step 1 is detached from window, since it never
  receives a SurfacePackage from the remote view, its detach shouldn't
  cause a reference count down on the remote view.

Test: atest android.autofillservice.cts.inline (sanity test)
Bug: 154683107

Change-Id: I2e6814ef3889de603f6e170efcb795b69ec9febe
2020-05-13 11:55:58 -07:00
Robert Carr
ebaaca1a46 SurfaceView: positionLost locking fix
positionLost can be called from CanvasContext::destroyHardwareResources
which runs asynchronously to the UI thread. This means we could be
simultaneously executing releaseSurfaces on the UI thread. We need
to expand the scope of mSurfaceControl lock in positionLost. While
we are here we add a block comment explaining the previously
undocumented locking strategy.

Bug: 156264048
Test: Existing tests pass
Change-Id: I9cdb6a0f7aeffd878f1755f240e8896f0fb8bf01
2020-05-13 18:29:59 +00:00
TreeHugger Robot
e0a73b1bb6 Merge "webkit: Update documentation for onJsAlert callback method" into rvc-dev 2020-05-13 18:15:31 +00:00
Matt Pietal
9788fd4afd Controls API - Flag controls support
Add a package manager flag so that apps can programmatically query
whether the device have system interface to support the Controls API

Bug: 156096063
Test: manual
Change-Id: I2dab2ecb762b59308c51615137f89733ff42caeb
2020-05-13 14:11:34 -04:00
Matt Casey
834c0f8ea4 Allow WindowManager.TYPE_SCREENSHOT to be focusable
Pre-R, the screenshot window was used just for screenshot animation. In
R, the window is also hosting tappable screenshot actions, which require
focus.

This change modifies TYPE_SCREENSHOT to no longer force it to be
unfocusable.

Test: Verify that screenshot window UI elements can work with talkback
    and accessibility scanner.
Bug: 153517161
Bug: 152583784
Change-Id: If81d9f94dff801c3483a2d834e692b4c77d80d7b
2020-05-13 14:01:41 -04:00
Changwan Ryu
31e2db92ce webkit: Update documentation for onJsAlert callback method
Fix documentation to clearly indicate that the default behavior is to
show WebView's own default dialog.

Also, change some wording to avoid confusion.

Bug: 154014645
Test: m -j offline-sdk-docs seems unbroken
Change-Id: I3f6676094e5472aa99bb014cf2b489f59133d094
2020-05-13 16:52:24 +00:00
TreeHugger Robot
eb191392e6 Merge "Don't try to recreate IncrementalFileStorages on re-commit." into rvc-dev 2020-05-13 16:01:39 +00:00
Yuichiro Hanada
93ec9b85e5 Revert tab key behavior on multiline EditTexts.
This CL reverts ag/10267783 effectively.
ag/10267783 makes tab key insert \t character on multiline text fields,
however, it broke the existing apps which depends on the previous
behavior.

Bug: 154290658
Test: manual - Tab key on multiline text fields advance focus
Test: atest TextViewTest#testKeyNavigation
Change-Id: I9836ce29321ca789bce6636514ce9a8dbf923ada
2020-05-13 21:26:36 +09:00
TreeHugger Robot
8ae0cfe36b Merge "Increase content capture buffer size to 500 Anecdotally this should cover typical messaging first screens whereas 100 events seems to be small." into rvc-dev 2020-05-13 01:57:06 +00:00
TreeHugger Robot
d775b6404f Merge "Allow some OpEntry#* methods for apps targeting R" into rvc-dev 2020-05-12 23:18:52 +00:00
Julian Odell
82c92bcf3c Increase content capture buffer size to 500
Anecdotally this should cover typical messaging first screens
     whereas 100 events seems to be small.

Test: make -j
Test: Manually start WhatsApp - check for lost events
Bug: 154777879
Change-Id: I3090584ec03714656948045189e0e0c068740c82
2020-05-12 23:02:55 +00:00
Alex Buynytskyy
4dbc0607ee Don't try to recreate IncrementalFileStorages on re-commit.
Bug: 156287164
Fixes 156287164
Test: atest PackageManagerShellCommandTest PackageManagerShellCommandIncrementalTest IncrementalServiceTest

Change-Id: I75e392a1fa84df8b6ac0b855233f9a2662998e96
2020-05-12 13:49:29 -07:00
Automerger Merge Worker
42f8135c6e Create TestApi for simulating a Data Stall on ConnectivityService.
This change adds a TestApi for simulating a Data Stall to
ConnectivityService. This allows for Data Stalls to be triggered without
having to manipulate the signals used by NetworkMonitor . This also
allows NetworkMonitor to update the ways it detects Data Stalls without
affecting CTS tests for ConnectivityDiagnosticsManager.

Bug: 148032944
Test: atest ConnectivityDiagnosticsManagerTest
Change-Id: Icad439efa2ab4c872c21d3ee6ceaae8c5b49f18d
Merged-In: Icad439efa2ab4c872c21d3ee6ceaae8c5b49f18d
(cherry picked from commit b06463a002)
2020-05-12 20:34:50 +00:00
Cody Kesting
0d8d6acd5b Set owner and administrator UIDs for test networks.
This change sets the owner and administrator UIDs for test networks when
their initial values match the UID for the app creating the test
network. This ensures that apps registering test networks can only make
themselves owners / administrators of the network.

Bug: 153449964
Test: atest NetworkAgentTest
Change-Id: I3a974700aa1d83cb285295ed1de0aa263e2e5b58
Merged-In: I3a974700aa1d83cb285295ed1de0aa263e2e5b58
(cherry picked from commit 35782280a2)
2020-05-12 20:33:42 +00:00
TreeHugger Robot
f30c225fcb Merge "Add OWNERS for display, haptics, input and power" into rvc-dev 2020-05-12 20:17:39 +00:00
TreeHugger Robot
291cf5d293 Merge "Deprecate WebSettings.setAppCacheEnabled and related." into rvc-dev 2020-05-12 19:18:10 +00:00
Michael Wright
2e7e81c950 Add OWNERS for display, haptics, input and power
Bug: 156349083
Test: N/A
Change-Id: Ia8afccfc2e470095ae3d52c827c0ac78b7c120ae
2020-05-12 19:11:13 +01:00
TreeHugger Robot
a76f65614e Merge "Fix cts fail for android.autofillservice.cts.augmented" into rvc-dev 2020-05-12 17:31:44 +00:00
Eino-Ville Talvala
ab3438ec1f Merge "Camera: Fix minor doc formatting error" into rvc-dev 2020-05-12 17:25:11 +00:00
Philip P. Moltmann
ac44350639 Allow some OpEntry#* methods for apps targeting R
Bug: 156254238
Test: built
Change-Id: Ie4a2cb155c40d46c52d44e0f53c05d52a8a9b523
2020-05-12 09:10:14 -07:00
Torne (Richard Coles)
76752c8f02 Deprecate WebSettings.setAppCacheEnabled and related.
Chrome will be removing the Application Cache API in future; deprecate
the APIs in WebView which allow Android apps to enable it.

Test: make offline-sdk-docs
Fixes: 156266477
Change-Id: I0feff5289706b5f7985013a18d9cf0e3e6b3ba78
2020-05-12 11:57:30 -04:00
Martijn Coenen
5019f6c50b Merge "Limit rename() workaround to /storage/emulated." into rvc-dev 2020-05-12 15:01:13 +00:00
lpeter
8e815316dd Fix cts fail for android.autofillservice.cts.augmented
In the test we trigger the manual autofill request programmatically,
because the focus isn't on the field, we will not get the callback
from IME.
It would be better not to ask IME for inline request if the request
is manual and the view is not focused because it's a simpler/safer
approach and manual request without focus should be rare.

Bug: 154661868
Test: atest CtsAutoFillServiceTestCases
Change-Id: I783b2542094cdea547ebd58ce89f30d9cd421708
2020-05-12 13:47:54 +00:00
Robert Horvath
f424274d8e Merge "Add PackageInstaller#uninstallExistingPackage" into rvc-dev 2020-05-12 11:40:10 +00:00
Robert Horvath
77880fa860 Add PackageInstaller#uninstallExistingPackage
This new API allows an app to be uninstalled silently by any app holding
the DELETE_PACKAGES permission, as long as the app is installed in
another user so won't be fully removed from the device.

Bug: 149601842
Test: atest UninstallExistingPackageTest
Merged-In: I69fe4d1dd4e9da83574b431257f7be6d1ac8b2bb
Change-Id: I69fe4d1dd4e9da83574b431257f7be6d1ac8b2bb
2020-05-12 09:18:56 +00:00
Riddle Hsu
8e726a2ef7 Merge changes from topic "b147213487" into rvc-dev
* changes:
  Send fixed rotation adjustments to the associated client
  Add support to override display adjustments by token
  Add fixed rotation display adjustments
2020-05-12 09:05:17 +00:00
Martijn Coenen
76ce2ccb19 Limit rename() workaround to /storage/emulated.
This workaround was intended to silently fix EXDEV move failures due to
the /Android/data and /Android/obb bind mounts. However, the workaround
should be limited to moves to *and* from the emulated filesystem. For
moves from the emulated filesystem to another filesystem (or
vice-versa), this would never have worked in the first place, and we
want to give the app this feedback, so it knows it needs to do a more
expensive copy operation and can show this in the UI. We know some apps
(like DocsUI) already handle this.

Public volumes (eg /storage/ABCD-1234) don't need this workaround, since
they don't have the bind mounts. Private volumes that aren't primary
don't have these bind mounts either.

Bug: 146430607
Test: N/A
Change-Id: I7bfe88e07708fe044ce8df02000a97cfad19bdee
2020-05-12 10:32:48 +02:00
Hongwei Wang
954820b047 Merge "Set mIsInMultiWindowMode in activity creation" into rvc-dev 2020-05-12 05:29:38 +00:00