Commit Graph

108010 Commits

Author SHA1 Message Date
Bernardo Rufino
60c39b3bc8 [Roll Forward] Block background custom toasts
Previous CL (ag/9699132) broke CTS ToastTest and was reverted (ag/9754500).
This was because the test was posting a background toast and verifying it
wasn't clickable. Test has been updated to use a foreground toast in ag/9754274
and I will also look into having it be executed in presubmit.(b/144810971).

-- Previous CL description (updated "Test:" lines)

To assess app compatibility problems early on, this CL blocks background
custom toasts in a non-secure way. We create a new method in the AIDL called
enqueueTextToast() that now contain the same parameters as
enqueueToast(), receiving the view created inside the app's process. But this
method will, in the future, contain a CharSequence instead of
ITransientNotification, for window creation inside the system.

We use PlatformCompat infrastructure to check if the change is enabled.

I learned with this change that if user blocks notifications for an app, it
won't be able to show background toasts, allowing me to re-use the foreground
check that was already in place.

This change will display a text toast (from the system) in case the app's
custom toast gets blocked, this is temporary to get feedback from
dogfood.

Test: With sample app, verify that:
      1. Posting text toast in bg works
      2. Posting custom toast in fg works
      3. Posting custom toast in bg does NOT work
Test: atest CtsToastTestCases CtsWindowManagerDeviceTestCases:ToastTest
      CtsWidgetTestCases:ToastTest CtsToastLegacyTestCases
Test: Working on CTS
Bug: 128611929

Change-Id: I25c6339c6adeb907878596332f57e2fa229bfda9
2019-11-20 09:16:31 +00:00
Yinglei Wang
0cf1081834 Merge "Make getStateDescription() in View none final" 2019-11-05 21:20:01 +00:00
Mady Mellor
ab190a8043 Merge "Bubble icon improvements" 2019-11-05 21:03:49 +00:00
Makoto Onuki
f054d0d245 Merge "Bidner shell command API proposal" 2019-11-05 19:42:58 +00:00
Taran Singh
90ebd2b809 Merge "Move startInput for WINDOW_FOCUS_GAIN to background thread" 2019-11-05 17:16:04 +00:00
Makoto Onuki
4c7073b017 Bidner shell command API proposal
Bug: 142751512
Test: "adb shell cmd jobschduler help"
Test: "adb shell cmd activity help"

Change-Id: I9174040cae72172e82d260d0ceb9ca5a69b72940
2019-11-05 09:13:07 -08:00
Felipe Leme
42a1773abe Merge "Improved UserSystemPackageInstaller.dump()" 2019-11-05 15:18:53 +00:00
TreeHugger Robot
60c4367006 Merge "Remove InputChannel::setToken" 2019-11-05 01:41:56 +00:00
Paul Mclean
be78503554 Merge "Adding USB Recording warning message to UsbResolverActivity." 2019-11-04 21:06:41 +00:00
Aran Ink
2b041061e3 Merge "Track and destroy inline URI grants separately from Notification URIs." 2019-11-04 20:31:06 +00:00
Paul McLean
07425c8c00 Adding USB Recording warning message to UsbResolverActivity.
Bug:136080195
Test: install UsbAccess and UsbPersistentPermissionsTestApp
(both want to handle USB connection events). Notice the
new warning message for the app(s) that haven't been
granted record permission.

Change-Id: I651ae5e6314a2d59ed4537aa7d7785e27e3b1a52
2019-11-04 12:25:07 -07:00
Miranda Kephart
82bfe7d6f7 Merge "Add corner flow for screenshots" 2019-11-04 19:06:45 +00:00
Aran Ink
979c9766df Track and destroy inline URI grants separately from Notification URIs.
Bug: 142492493
Bug: 137398133

Test: Unit tests pass. Manual testing with an app configured to receive images via RemoteInput can access and display image URIs after the notification has been canceled, but before the notification entry has been removed from the shade.

Change-Id: If64ae7eff7293df3317a1f629977aaaccd866b32
2019-11-04 12:56:41 -05:00
TreeHugger Robot
90edec903a Merge "Do not enforce partition restrictions on component-override" 2019-11-04 17:31:43 +00:00
Miranda Kephart
ea2e67a5a0 Add corner flow for screenshots
Instead of showing a notification, the screenshot animates into the
bottom left corner of the phone. Tapping on it leads to the same
intent as tapping "Edit" on the notification would. The screenshot
disappears after 8 seconds.

Bug: 137153302
Test: adds feature behind flag, tested that behavior remains the same
if flag is false

Change-Id: I4f48ba7de36f298bd6a66439ea6885fc92a8cb9c
2019-11-04 12:13:19 -05:00
TreeHugger Robot
f822d418e3 Merge "Add additional javadoc for listener parameter." 2019-11-04 16:27:33 +00:00
Martijn Coenen
d231b2a363 Merge "Don't hold sProxyLock while retrieving interface descriptors." am: ef6fe13c77 am: d4d27b403c
am: 3d4d4253e4

Change-Id: I27540c32f7150eff152b324c4edccc6afcce6b92
2019-11-04 00:29:53 -08:00
Martijn Coenen
3d4d4253e4 Merge "Don't hold sProxyLock while retrieving interface descriptors." am: ef6fe13c77
am: d4d27b403c

Change-Id: Ibcdc21838228db0286f3ea4538fd58a03370db35
2019-11-04 00:24:19 -08:00
Martijn Coenen
d4d27b403c Merge "Don't hold sProxyLock while retrieving interface descriptors."
am: ef6fe13c77

Change-Id: Ie54978b2f19e42c47992e04c2f41c55d8c61df5b
2019-11-04 00:13:53 -08:00
Martijn Coenen
ef6fe13c77 Merge "Don't hold sProxyLock while retrieving interface descriptors." 2019-11-04 07:51:11 +00:00
TreeHugger Robot
591f29d830 Merge "Documenting PendingIntent identifying flags" 2019-11-04 01:54:07 +00:00
Siarhei Vishniakou
6742983aa8 Remove InputChannel::setToken
The token is now generated at the native level, inside InputTransport,
when you open an inputchannelpair. It is read-only.

Bug: 142581626
Test: presubmit
Change-Id: I67314f9854c2f720eb4fc2cb489755eae8863f8f
2019-11-01 18:27:42 -07:00
Suprabh Shukla
e513a8d14c Documenting PendingIntent identifying flags
Test: make docs

Bug: 143764310
Change-Id: I04accd4ae6ff3eb260ca96744c00a995e081688c
2019-11-01 17:55:03 -07:00
Evan Rosky
5998c1831f Merge "Add a remote control mechanism for window containers" 2019-11-02 00:26:59 +00:00
Jordan Liu
8e9d9055b0 Merge "Expose Context.sendOrderedBroadcast with appop" 2019-11-01 23:21:57 +00:00
Makoto Onuki
d5d07c8d0c Merge "Undo the jobscheduler / device idle initialization with callbacks" 2019-11-01 22:08:50 +00:00
Philip P. Moltmann
cdc4a55cd1 Merge changes from topic "networklocationFeatureId"
* changes:
  Pipe through featureId for network location checks
  Support feature context in TelephonyManager
2019-11-01 22:01:59 +00:00
Jordan Liu
54735539fb Expose Context.sendOrderedBroadcast with appop
Bug: 143100231
Test: atest ContextTest#testSendOrderedBroadcastWithAppOp
      atest ContextTest#testSendOrderedBroadcastWithAppOp_NotGranted

Change-Id: Ia75d0db11f337769eaf3cf5436e09a7d38b0564c
2019-11-01 14:01:09 -07:00
Philip P. Moltmann
bcd37b9c70 Merge changes from topic "RecognitionServiceFeatureId"
* changes:
  Pipe through featureId from caller to noteOps in RecognitionService
  Add featureId to PermissionChecker
2019-11-01 19:45:59 +00:00
Chris Tate
71ce21eb91 Merge "Move BatteryStatsInternal to services.jar" 2019-11-01 18:00:33 +00:00
TreeHugger Robot
91bdd4f00e Merge "Camera: Add bokeh mode tags in camera metadata" 2019-11-01 17:11:11 +00:00
Mike Ma
2acaae920a Merge "Downgrade error level when proc file is empty" 2019-11-01 17:03:39 +00:00
Philip P. Moltmann
2d628b73bb Support feature context in TelephonyManager
...Managers are supposed to use the passed in context to support e.g.
alternate user or package contexts. Not sure why this is not the case
for TelephonyManager.

Hence special case the support for feature-contexts.

Test: atest CtsAppOpsTestCases:android.app.appops.cts.AppOpsLoggingTest#getCellInfo
Bug: 136595429
Change-Id: I7f498e282a34e39da6a1f6c129eff09674dce795
2019-11-01 08:54:36 -07:00
Makoto Onuki
152742f27a Undo the jobscheduler / device idle initialization with callbacks
We'll be able to expose system APIs from jobscheduler-framework.jar and
use them from framework-minus-apex.jar, so these elaborated initialization
will not be needed.

Bug: 142281756
Test: boot, "dumpsys batterstats"
Change-Id: I957642fc2573818d138450747e0690d7176636ad
2019-11-01 08:19:38 -07:00
TreeHugger Robot
12eafbf173 Merge "Surface CONFIRM and REJECT vibration constants" 2019-11-01 14:26:35 +00:00
Mike Ma
9688474172 Downgrade error level when proc file is empty
Use Slog.w instead of Slog.wtf for a few empty cases when reading
proc files.

There have been quite a few issues around reporting error at Slog
.wtf level in the past. Although Slog.wtf should not crash itself,
it has indirectly caused a few crashes due to improper handling of
wtf errors e.g. arose from incorrectly mocking BatteryStatsImpl.

Test: Manual
Change-Id: Idce018c928a1bb0f3d4c139382d090be009c291d
2019-11-01 02:26:09 -07:00
Remi NGUYEN VAN
970fbf37b5 Merge "Add API to set the sll_protocol on PacketSocket" am: 0d6c308c39 am: 7919e04f5b
am: 64e2f81eba

Change-Id: I20c1462b47babbaea7c9fcab08692272a242fcf5
2019-10-31 22:09:20 -07:00
Remi NGUYEN VAN
64e2f81eba Merge "Add API to set the sll_protocol on PacketSocket" am: 0d6c308c39
am: 7919e04f5b

Change-Id: I4249450e9204d732c1c6548f9af88362f157bb78
2019-10-31 21:57:21 -07:00
Remi NGUYEN VAN
7919e04f5b Merge "Add API to set the sll_protocol on PacketSocket"
am: 0d6c308c39

Change-Id: I203f26229dcd580704665f7a07a391facef49a17
2019-10-31 21:50:40 -07:00
Remi NGUYEN VAN
0d6c308c39 Merge "Add API to set the sll_protocol on PacketSocket" 2019-11-01 04:34:44 +00:00
Christopher Tate
ca4e621306 Move BatteryStatsInternal to services.jar
Bug: 140833849
Test: boot & run normally
Test: m checkbuild
Change-Id: Ifb3e4a69073380e09348572fdd7b0e5386e00525
2019-10-31 16:53:48 -07:00
Hui Yu
a86a36b184 Merge "Add process capability as a new dimension." 2019-10-31 23:11:21 +00:00
Makoto Onuki
caff9d2cc2 Merge "Initialize JobScheduler without using preload" 2019-10-31 22:32:24 +00:00
TreeHugger Robot
6807fa4c81 Merge "Clean up code for experiment of JIT'ing priv apps" 2019-10-31 21:05:57 +00:00
Nikita Dubrovsky
b6b8c731a4 Merge "Add debug logging for cursor logic in TextView and Editor" 2019-10-31 19:56:21 +00:00
yingleiw
c9cb2e8307 Make getStateDescription() in View none final
Do not make getStateDescription final, since it can cause
compatibility issues with existing derived classes that define
a getStateDescription. Also replaced call to
getContentDescription() to mContentDescription. This is because
if a subclass overrides it, we don't want it to affect the value
used in accessibility service (cause divergence in accessibility
event and accessibilityNodeInfo).

Bug: 143652980
Test: no needed
Change-Id: I36c94c85eb258b3c9474090d841c925331d22d73
2019-10-31 12:38:03 -07:00
Kweku Adams
f8ab0aa52b Merge "Move heap dump sharing to SHELL." 2019-10-31 19:23:30 +00:00
TreeHugger Robot
abc015499a Merge "DO NOT MERGE - qt-qpr1-dev-plus-aosp-without-vendor@5915889 into stage-aosp-master" into stage-aosp-master 2019-10-31 18:38:40 +00:00
TreeHugger Robot
20277b8309 Merge "Set "today" and "selected" for Datepicker when using Calender" 2019-10-31 18:34:03 +00:00
Paul Sowden
afe846d879 Add additional javadoc for listener parameter.
Test: make -j20 docs
Change-Id: I6f8c30014c63bc41609b9a683c2ddd5de48eb713
2019-10-31 11:01:56 -07:00