Commit Graph

15119 Commits

Author SHA1 Message Date
TreeHugger Robot
0824c257af Merge "Flip off use of old Chooser targets by default." 2020-11-03 01:27:08 +00:00
Maryam Karimzadehgan
4611a1ae7d Merge "Add flag to get the name of the Model file from the flag in case we want to try out different models. In addition, we should not log touches in the middle of the screen for logging so moving the block at the very beginning." 2020-11-03 00:28:42 +00:00
TreeHugger Robot
9da1385292 Merge "Remove preRender input" 2020-11-02 22:35:24 +00:00
Sean Stout
5aa2c79d89 Merge "Implement Phase 3 of per-display power states" 2020-11-02 22:22:15 +00:00
Maryam Karimzadehgan
3c2f51c994 Add flag to get the name of the Model file from the flag in case we want
to try out different models. In addition, we should not log touches in
the middle of the screen for logging so moving the block at the very
beginning.

Test: unittest, manual test
Bug: 150170384
Change-Id: I6ecb556fea01f26323248b999d17c7b1d1b7eeb7
2020-11-02 22:05:47 +00:00
Lucas Dupin
690a360fad Create cross window blur drawable
This introduces BackgroundBlurDrawable that does cross-window blurs
The drawable should not be created manually, it should be retrieved
from the ViewRootImpl

Test: manual
Bug: 159712515
Bug: 171916625
Change-Id: I697e93fc95ba3d0a7211b235b1c5d48a1968b939
2020-11-02 04:26:13 +00:00
Sean Stout
efa2acc6e9 Implement Phase 3 of per-display power states
In this phase a DisplayPowerController is created per-display. However
each display is still controlled by the default display's
DisplayPowerController.

Bug: 138328918
Test: manual - Boot device and toggle display power
Change-Id: I4c608d1e18476a87d2da4bc1c120d62c39db25eb
2020-10-30 17:38:41 -07:00
Alison Cichowlas
fb4a768c97 Flip off use of old Chooser targets by default.
Test: ChooserActivityTest
Bug: 170144291
Change-Id: Ie4e27f0e4506da7ebb97efc3840a64e0c39729b9
2020-10-30 16:43:33 -04:00
Alison Cichowlas
0b379c9098 Merge "Always reset viewpager in RTL layouts, whether or not it's tabbed." 2020-10-30 13:35:36 +00:00
Lan Wei
a401308ab7 Merge "Avoid bad InputConnection call crashing the app" 2020-10-29 23:02:32 +00:00
Alison Cichowlas
702cf39534 Always reset viewpager in RTL layouts, whether or not it's tabbed.
Test: Repro instructions in bug
Fixes: 169138573
Change-Id: I889c13150979ae4bf7410f53e3dc0bad798402c1
2020-10-29 16:53:35 -04:00
Winson Chung
e69fdd7ac0 Merge "Allow disabling protolog exceptions" 2020-10-29 16:17:25 +00:00
TreeHugger Robot
7b6e78f975 Merge "Fix the wrong package name to return the wrong resources." 2020-10-29 16:01:03 +00:00
Mathew Inwood
bb05958365 Merge "Add maxTargetSdk restriction to unused APIs." 2020-10-29 15:23:24 +00:00
Taran Singh
72de8ead9e Remove preRender input
Cleanup unused pre-render input. We've no plans to enable it.
It adds unnecessary complexity.

Bug: 159201509
Bug: 167948123
Bug: 118599175

Test: atest CtsInputMethodTestCases

Change-Id: I32fe3759b9aeb56c868f9abf42bab124b9b83374
2020-10-29 07:57:00 -07:00
Mathew Inwood
8e742f928e Add maxTargetSdk restriction to unused APIs.
These are APIs that have @UnsupportedAppUsage but for which we don't
have any evidence of them currently being used, so should be safe to
remove from the unsupported list.

This is a resubmit of ag/12929664 with some APIs excluded that caused
test failures; see bugs 171886397, 171888296, 171864568.

APIs excluded:
Landroid/bluetooth/le/ScanRecord;->parseFromBytes([B)Landroid/bluetooth/le/ScanRecord;
Landroid/os/Process;->myPpid()I
Landroid/os/SharedMemory;->getFd()I
Landroid/hardware/input/InputManager;->INJECT_INPUT_EVENT_MODE_WAIT_FOR_FINISH:I

Bug: 170729553
Test: Treehugger
Change-Id: I8285daa8530260251ecad6f3f38f98e263629ca7
2020-10-29 11:51:12 +00:00
Chalard Jean
434b1ccbb4 Merge changes I623e2983,I8b95e020 am: ec1966e372 am: bf84b9239b am: 441c5bc2e8 am: d27c16ab39
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1479476

Change-Id: Ief538b4dca6dca36686327042beacdb113e323e5
2020-10-29 11:17:30 +00:00
Galia Peycheva
20f62e9098 Merge "Create a window style attribute for background blur" 2020-10-29 11:07:20 +00:00
Chalard Jean
d27c16ab39 Merge changes I623e2983,I8b95e020 am: ec1966e372 am: bf84b9239b am: 441c5bc2e8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1479476

Change-Id: Iacf53dd5c4747e7d394d8aa1f6de2d66bfd80cca
2020-10-29 10:52:05 +00:00
Lan Wei
1e72ef2893 Avoid bad InputConnection call crashing the app
Update InputConnection#getTextBeforeCursor(int, int) and
InputConnection#getTextAfterCursor(int, int) API to
specify that the paramter {@code n} must be non-negative.
If the IME using the API incorrectly, throw
IllegalArgumentException.

Also update these two APIs that return nullable result (no
behaivor change). For editor App, return null for bad case.

Test: atest BaseInputConnectionTest#testInvalidGetTextBeforeOrAfterCursorRequest
Test: atest InputConnectionWrapperTest#testInvalidGetTextBeforeOrAfterCursorRequest

BUG: 169114026

Change-Id: I95169735198f8363c981a61e20234dfebfd645b1
2020-10-29 16:51:49 +08:00
Felka Chang
d168885c07 Fix the wrong package name to return the wrong resources.
It should pass mSuspendingPackage instead of mSuspendedPackage as the
parameter of the getResourcesForApplication.

Root cause: The intellij is very smart to provide the autocomplete
    options and the developer choose the wrong option.
Solution:
    * Add file_pattern in TEST_MAPPING to trigger the CTS tests.
    * The developer should take the autocomplete option very
      carefully especially the options are very alike.

Fixes: 171835218
Fixes: 171779738
Test: atest CtsSuspendAppsTestCases
Test: atest -p frameworks/base/core/java/com/android/internal/app
Change-Id: I0a213e5fcbf207b89f203e25cf1ace1b8406a879
2020-10-29 15:44:27 +08:00
Chalard Jean
1f832406ca Manage VPN legacy state separately from NetworkInfo
This is mainly a cleanup, but is also necessary for the
network selection project.

This is for network selection ultimately because NetworkSelection
needs NetworkAgents to use the newer API introduced in R rather
than the legacy internal API. Using that API forbids communicating
to ConnectivityService through NetworkInfo, and does not support
the FAILED state because there is no usage in connectivity.
In VPN, FAILED is used only to communicate a state to Settings
and it does this through IConnectivityManager.getLegacyVpnInfo,
which already is using an int to communicate this information.

Splitting the legacy state from NetworkInfo not only is simpler
ultimately because it's the format in which it's consumed, but
also will allow removing NetworkInfo completely.

Test: FrameworksNetTests NetworkStackTests
Bug: 167544279
Change-Id: I8b95e020919e38a5166892221096db6271985574
2020-10-29 11:43:20 +09:00
Winson Chung
4fff058e9f Allow disabling protolog exceptions
Bug: 171417169
Test: Build and make sure protologs still works and sysui gradle
      project can build as well
Change-Id: I29684d8b3b5fc49e8179dc15eac9c37cf706322b
2020-10-28 19:27:09 -07:00
Hongwei Wang
286c33a5c5 Merge "Revert "Add maxTargetSdk restriction to unused APIs."" 2020-10-28 23:58:21 +00:00
Hongwei Wang
050275cd83 Revert "Add maxTargetSdk restriction to unused APIs."
This reverts commit 72f07d6a8a.

Reason for revert: Droidcop-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?testMethod=testAppZygotePreload&testClass=android.app.cts.ServiceTest&atpConfigName=suite%2Ftest-mapping-presubmit-retry_cloud-tf&testModule=CtsAppTestCases&fkbb=6936597&lkbb=6936969&lkgb=6936551&testResults=true&branch=git_master&target=cf_x86_phone-userdebug>, bug b/171886397

Bug: 171886397
Change-Id: Ibe0f0430a3451477c1ee8ef56a596e91ea1e7672
2020-10-28 20:16:22 +00:00
Mathew Inwood
ee5d369323 Merge "Add maxTargetSdk restriction to unused APIs." 2020-10-28 09:39:20 +00:00
Kevin Chyn
ec8173509a Merge "Change BiometricService/AuthController interface to sensorId" 2020-10-28 03:44:37 +00:00
Mathew Inwood
72f07d6a8a Add maxTargetSdk restriction to unused APIs.
These are APIs that have @UnsupportedAppUsage but for which we don't
have any evidence of them currently being used, so should be safe to
remove from the unsupported list.

Bug: 170729553
Test: Treehugger
Change-Id: I4c8fd0006f950de9955242e93968fb0996ceb372
2020-10-27 15:46:07 +00:00
Galia Peycheva
ba9ba61243 Create a window style attribute for background blur
Add a hidden attribute to the Window style for background blur radius

Bug: 167166562
Test: m && flash && verify with test app

Change-Id: Id785ed20da26033e7f777762bf770b78b4a02992
2020-10-27 16:00:50 +01:00
Kevin Chyn
cc07fa7dd6 Change BiometricService/AuthController interface to sensorId
This way, AuthController (SystemUI) can query the system to check
specific info for each sensor.

Test: No effect on existing devices
Test: atest com.android.systemui.biometrics
Test: atest com.android.server.biometrics

Bug: 171071087

Change-Id: I2a33aa25aac880764000d296de328d326709d1a0
2020-10-26 12:23:05 -07:00
Hall Liu
22244c8ed3 Merge "Update PhoneStateListener#onOutgoingEmergencySms" am: c5d02da0f6 am: b37753c29a am: 75c5434ddd
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1470691

Change-Id: I830b4bc2db3c53c5c2f21ba1f099af8eaccbfe70
2020-10-23 21:03:16 +00:00
Hall Liu
c5d02da0f6 Merge "Update PhoneStateListener#onOutgoingEmergencySms" 2020-10-23 19:15:22 +00:00
Songchun Fan
8c7bfcd5ab Merge "Revert "Revert "[incremental/pm] LauncherApps APIs for loading state and progress""" 2020-10-23 17:44:53 +00:00
Treehugger Robot
00a5b9b4d4 Merge "Add a mutability flag to the PendingIntent" am: 2a4ac569b0 am: 0cfb318d10 am: 49a146399c am: a230de92fe
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1456120

Change-Id: I1e0adcc9affae154318f2e92a75ce190c97d3b10
2020-10-23 11:24:41 +00:00
Treehugger Robot
a230de92fe Merge "Add a mutability flag to the PendingIntent" am: 2a4ac569b0 am: 0cfb318d10 am: 49a146399c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1456120

Change-Id: I7018d8afbd43690810d6b00683c6e7d26091e8ae
2020-10-23 11:11:41 +00:00
Treehugger Robot
2a4ac569b0 Merge "Add a mutability flag to the PendingIntent" 2020-10-23 09:49:27 +00:00
TreeHugger Robot
bcf16c151e Merge "Remove PackageManager.getResourcesForApplicationAsUser API" 2020-10-23 05:52:01 +00:00
TreeHugger Robot
acd46f5672 Merge "IME API: InputConnection#getSurroudingText(int, int, int)" 2020-10-23 03:18:54 +00:00
Hall Liu
cd3ad04afd Expose onEmergencyNumberListChanged, semantics change am: e182543791 am: f8e5b6fd6e am: 266e87e5a9
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1469715

Change-Id: I68d51c9e91f3a2c08a474f7848d4fda1693c21d9
2020-10-22 22:21:18 +00:00
Hall Liu
f8e5b6fd6e Expose onEmergencyNumberListChanged, semantics change am: e182543791
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1469715

Change-Id: I00eef453ff044c5c5bc6878b61277c5e133b3dbe
2020-10-22 20:53:11 +00:00
Jeff Sharkey
a0cdb4ca3f Merge "Migrate hot codepaths to formatSimple()." 2020-10-22 20:31:28 +00:00
Jeff Sharkey
305ef9e1cf Migrate hot codepaths to formatSimple().
The recently added TextUtils.formatSimple() can efficiently format
simple strings, roughly 6.5x faster than using String.format().

This change starts using this new method in hot codepaths identified
from pprof traces, and this CL alone should reduce system_process CPU
usage by 0.24%.  Linked bug has detailed pprof screenshots.

Bug: 170978902
Test: atest FrameworksCoreTests:android.text.TextUtilsTest
Exempt-From-Owner-Approval: trivial refactoring
Change-Id: Ie5a21a24be6dfcdb29768fe235e20f050fc111c7
2020-10-22 12:48:13 -06:00
Hall Liu
adfc80c4d5 Update PhoneStateListener#onOutgoingEmergencySms
Update the callback for emergency SMS to follow the same pattern as for
emergency calls for API consistency.

Fixes: 168269065
Test: atest CtsTelephonyTestCases:PhoneStateListenerTest
Change-Id: If27771aef1858ea92dd620b56368d1a6a4f61ab3
Merged-In: If27771aef1858ea92dd620b56368d1a6a4f61ab3
2020-10-22 11:34:28 -07:00
Hall Liu
77b5c5a31b Merge changes from topic "move-emergency-phone-update"
* changes:
  Update docs for onEmergencyNumberListChanged
  Call onOutgoingEmergencyCall only once.
  Expose onEmergencyNumberListChanged, semantics change
2020-10-22 17:13:52 +00:00
Steven Moreland
1d09a22ec4 Merge "Remove declaration of hidl manager -> base dep" am: 4ff4b2ee17 am: 742771fdd7 am: e798d05a73 am: d53ccbc7bf
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1467918

Change-Id: If382fe51b02209c72089b7c0965f63c52fe1614f
2020-10-22 06:11:13 +00:00
Steven Moreland
d53ccbc7bf Merge "Remove declaration of hidl manager -> base dep" am: 4ff4b2ee17 am: 742771fdd7 am: e798d05a73
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1467918

Change-Id: I053f441b90c710a7fed75705b3e170b890acb193
2020-10-22 05:50:54 +00:00
Steven Moreland
4ff4b2ee17 Merge "Remove declaration of hidl manager -> base dep" 2020-10-21 23:14:11 +00:00
Hall Liu
e182543791 Expose onEmergencyNumberListChanged, semantics change
Expose the onEmergencyNumberListChanged method, which seems to have been
left hidden inadvertently when introduced.

Add a new version of onOutgoingEmergencyCall that supplies a
subscription ID and deprecate the old one. Along with this, send
emergency call events from any subscription to all listeners regardless
of which subscription the listener specified.

Test: atest CtsTelecomTestCases:OutgoingCallTest
Bug: 162647577
bug: 165660452
Change-Id: Ia0e10bfb3376ff82d03a6dbc4bf71c22b0ace366
Merged-In: Ia0e10bfb3376ff82d03a6dbc4bf71c22b0ace366
2020-10-21 16:07:04 -07:00
Songchun Fan
56838fba12 Revert "Revert "[incremental/pm] LauncherApps APIs for loading state and progress""
This reverts commit 69475be847.
Also reverts commit Iaf8e2c075f188df95c68824b71362629c6adabfc.

Reason for revert: Trying again but will submit with new tests

BUG: 165841645
Test: atest NexusLauncherOutOfProcTests
Test: atest LauncherAppsSingleUserTest
Test: atest LauncherAppsMultiUserTest
Test: atest LauncherAppsProfileTest
Test: atest LimitAppIconHidingTest
Change-Id: I5ed5871ccddefbd922b3aa3ee4c1ad53cc0bfa9b
2020-10-21 14:20:20 -07:00
Jeff DeCew
ddc2dcce49 Merge changes I6fd9aeec,I296e9d53
* changes:
  Minimize use of header in adjusting notification colors.
  Remove setExpanded from the NotificationHeaderView
2020-10-21 19:12:53 +00:00