Commit Graph

15545 Commits

Author SHA1 Message Date
Seigo Nonaka
07a787dbe6 Merge "Add OWNERS for font manager related module" am: 61bb2cfccc am: 63c0ffd31e am: 6997779819
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1557448

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8c476fee426ec7998adb95f914c476ca7bf1950b
2021-01-25 17:34:49 +00:00
Seigo Nonaka
6997779819 Merge "Add OWNERS for font manager related module" am: 61bb2cfccc am: 63c0ffd31e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1557448

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic814c65f7885d9f1b0f25adcf6fdf1f7dab44cb4
2021-01-25 17:17:30 +00:00
Wu Ahan
b274cd0165 Merge "Add jank instrumentation logic in keyguard" 2021-01-25 14:46:14 +00:00
Artur Satayev
5744991315 Merge "Do not propogate test api access flags to Zygote." 2021-01-25 14:33:42 +00:00
Hai Zhang
0b4f1718f8 Move role into module.
These changes have to be in this CL together because:

- Code in service-permission depends on IRoleManager in
framework-permission, so the APIs in framework-permission and the code
in service-permission need to be moved together.

- The changes to service-permission build rules doesn't make sense
without the code moved in, so they have to be together as well.

Other details:

- framework-annotations: Several annotations are added into
framework-annoatations. Since the discussion with API council seems to
allow user IDs in system server in-process APIs, @UserIdInt and
@AppIdInt is added. @MainThread and @AnyThread is added since
@WorkerThread is already added. @CallSuper is added since @CheckResult
is also already added and they are similar in terms of category of
functionality.

- framework-permission-s-shared-srcs: 3 classes (and 2 AIDL files)
from framework is copied as shared source files and jarjared for
framework-permission, and an additional 3 is added for
service-permission as service-permission-shared-srcs. Similar to
framework-wifi and service-wifi, the 3 classes in framework-permission
is also available to service-permission by the stub library
framework-permission-pre-jarjar, and the other 3 classes used only for
service-permission is included separately to minimize our impact on
classes loaded into boot classpath. framework-permission and
service-permission shares the same jarjar rules to make sure the
classes remain available, and for the same reason framework-permission
cannot be shrank during any optimization.

- framework-permission-s-shared: A java_library target for
framework-permission-shared-srcs is created to make sure that the
public classes won't be counted as APIs, as it would be if directly
included as srcs for framework-permission
java_sdk_library. service-permission-shared is the same thing for
service-permission.

- framework-permission-s: A new java_sdk_library target created to be
loaded into bootclasspath by Android S+.

- Dumpsys Protobuf: The dumpsys protobuf
file (rolemanagerservice.proto) is moved into the module, and both the
platform (incident.proto) and the module uses protoc-gen-javastream to
generate the Java classes from it. This should be fine since it's a
"source level inclusion", and we jarjar the generated classes in our
module to avoid conflict with platform copies.

Bug: 158736025
Test: manual
Test: device boots, default apps can be changed successfully.
Change-Id: I1914774f631e51d0c587a7e527a1c9bc05ee1595
2021-01-24 12:55:16 -08:00
Nicholas Ambur
ed1413316f Merge changes from topic "hotword-battery-saver"
* changes:
  add API for ST clients run in battery saver mode
  add SOUND_TRIGGER_RUN_IN_BATTERY_SAVER permission
  add SoundTrigger service modes in battery saver
2021-01-23 21:51:13 +00:00
SongFerng Wang
1581f4fc97 Merge "Improve AllowedNetworkTypesForReason and refactor PreferredNetworkType" 2021-01-23 07:41:10 +00:00
Nicholas Ambur
28cc6364d6 add API for ST clients run in battery saver mode
New system API interface for both SoundTriggerManager and
AlwaysOnHotwordDetector to indicate if a recognition should run in
battery saver mode or not.

Clients supply this information through the existing startRecognition
calls, and the client must hold a new privledged permission,
SOUND_TRIGGER_RUN_IN_BATTERY_SAVER, to indicate this intention.

As a prerequisite, the device PowerManagerService must have the
SoundTrigger service enabled in the battery saver mode battery policy.
If not enabled, recognition will be paused as if the client did not
provide the indication to run in battery saver mode.

Bug: 172294448
Test: build with Google search apk using this feature and verify
recognition keeps running in battery saver mode

Change-Id: Ia43be99290e6fd7c50ff8e4908d6c60ea513b19a
2021-01-22 18:24:39 -08:00
SongFerngWang
7d95185d46 Improve AllowedNetworkTypesForReason and refactor PreferredNetworkType
- Add more reasons of allowed network type
  - ALLOWED_NETWORK_TYPES_REASON_USER
  - ALLOWED_NETWORK_TYPES_REASON_CARRIER
- Add @systemApi for below
  - ALLOWED_NETWORK_TYPES_REASON_USER
  - ALLOWED_NETWORK_TYPES_REASON_POWER
  - ALLOWED_NETWORK_TYPES_REASON_CARRIER
  - setAllowedNetworkTypesForReason API
  - getAllowedNetworkTypesForReason API
  - getAllowedNetworkTypesBitmask API
- Add Public for below
  - CARRIER_NR_AVAILABILITY_NONE
  - CARRIER_NR_AVAILABILITY_NSA
  - CARRIER_NR_AVAILABILITY_SA
  - KEY_CARRIER_NR_AVAILABILITY_INT
- @Deprecated API
  - setPreferredNetworkTypeBitmask
  - getPreferredNetworkTypeBitmask
  - setAllowedNetworkType
  - getAllowedNetworkType
- Add a new way to notify allowedNetworkType at PhoneStateListener
- Replace KEY_NR_ENABLED_BOOL with KEY_CARRIER_NR_AVAILABILITY_INT

Bug: 161434786
Test: atest TelephonyManagerTest#testSetAllowedNetworkTypesForReason
(PASS)
atest TelephonyManagerTest#\
testSetAllowedNetworkTypesForReason_moreReason
(PASS)
atest PhoneStateListenerTest#\
testOnAllowedNetworkTypesChangedByRegisterPhoneStateListener
(PASS)

Change-Id: I3d0c119a0c2a30c56b0c127ba6525f8992b4e9dd
2021-01-23 06:51:05 +08:00
Artur Satayev
90264e56e1 Do not propogate test api access flags to Zygote.
The flow has been replaced by @ChangeId ALLOW_TEST_API_ACCESS, making
old approach obsolete.

Bug: 147113465
Test: presubmit would be sufficient
Change-Id: I9cf8f80abb0165d4aefbf943bade57f5e031904b
2021-01-22 18:47:12 +00:00
Seigo Nonaka
580f6ddeb2 Add OWNERS for font manager related module
Bug: N/A
Test: N/A
Change-Id: I8a653349bd6df6365e1d6cbb2fc3b3ac10c8fcd7
2021-01-22 10:07:27 -08:00
Dmitri Plotnikov
9a8a94c10c Convert SensorPowerCalculator to work with BatteryUsageStats
Test: atest FrameworksCoreTests:com.android.internal.os.GnssPowerCalculatorTest
Test: atest FrameworksCoreTests:com.android.internal.os.SensorPowerCalculatorTest
Bug: 175644968
Bug: 173546795

Change-Id: I97cc3f75836bdcc719428dc2bb8d8464a609bf14
2021-01-21 18:47:12 -08:00
Dmitri Plotnikov
dfce528997 Convert MobileRadioPowerCalculator to work with BatteryUsageStats
Test: atest FrameworksCoreTests:com.android.internal.os.MobileRadioPowerCalculatorTest
Bug: 175644968
Change-Id: Iea088a14adde4255767ca76d8ec4c40b404cb33c
2021-01-21 13:19:21 -08:00
TreeHugger Robot
aca883298a Merge "Add supportedAttributes param for spell checker." 2021-01-21 19:45:17 +00:00
Josh Tsuji
fd577558f6 Merge "Adds the power button unlock animation and plumbs detailed wake/sleep reason to System UI." 2021-01-21 18:55:52 +00:00
TreeHugger Robot
8197beb008 Merge "Make IInputMethodManager to oneway (9/N)" 2021-01-21 03:10:40 +00:00
Kohsuke Yatoh
036c61877a Merge "Add missing textservice OWNERS files." am: 0f4112a760 am: 49023f3cd8 am: 782d427971
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1554552

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie00b4339b17b58e4041b506d23c8f7a984839481
2021-01-21 01:20:06 +00:00
Josh Tsuji
cb27bd1a83 Adds the power button unlock animation and plumbs detailed wake/sleep reason to System UI.
Test: unlock the phone using either the power button or lifting it
Bug: 169693662
Change-Id: I567555e6ee04f369ce7f4b32744639be70583112
2021-01-20 20:08:37 -05:00
Kohsuke Yatoh
782d427971 Merge "Add missing textservice OWNERS files." am: 0f4112a760 am: 49023f3cd8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1554552

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ifeae70e9e0e68b1f0420c95676c3a2445c9433ef
2021-01-21 01:00:21 +00:00
Kohsuke Yatoh
0f4112a760 Merge "Add missing textservice OWNERS files." 2021-01-20 23:16:33 +00:00
Kohsuke Yatoh
93d47b0487 Add supportedAttributes param for spell checker.
Bug: 166304720
Test: atest CtsInputMethodTestCases:SpellCheckerTest
Change-Id: I22f4a59a0c8ccb43f799351062f9fabca42403cd
2021-01-20 20:06:12 +00:00
satayev
c9805723c9 Merge "Allow clearing a single change id for tests usage." am: 2805c99594 am: 3bbe9c336f am: 311ed3bc6a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1553537

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I92f1b8bf5d2675ea88cf8b67cec37a381178e10a
2021-01-20 18:56:44 +00:00
satayev
2dcbe22daa Merge "Refactor PlatformCompat and related files." am: 5d37ff2d33 am: 3cfd32b11f am: 1c8e894bd8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1553536

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If7d1fe2f9b0165c3bb46a64b77a2f00756f207e3
2021-01-20 18:55:11 +00:00
Kohsuke Yatoh
b1d2fe86f7 Add missing textservice OWNERS files.
Test: n/a
Change-Id: I56939ce3a22c72ac489e4d9248de9e0ce4ee9413
2021-01-20 18:53:11 +00:00
satayev
311ed3bc6a Merge "Allow clearing a single change id for tests usage." am: 2805c99594 am: 3bbe9c336f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1553537

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie864851627231669743899b8e0d110635cee6c60
2021-01-20 18:49:03 +00:00
satayev
1c8e894bd8 Merge "Refactor PlatformCompat and related files." am: 5d37ff2d33 am: 3cfd32b11f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1553536

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia183bbd2338415608ad962e80336e05bc6d99612
2021-01-20 18:48:02 +00:00
satayev
2805c99594 Merge "Allow clearing a single change id for tests usage." 2021-01-20 17:48:52 +00:00
TreeHugger Robot
b4707f9a04 Merge "Option to skip profile password requirement during password enrolment" 2021-01-20 14:40:24 +00:00
Artur Satayev
21900cb6ee Allow clearing a single change id for tests usage.
Add clearOverrideForTest(changeId, packageName) to remove a single id
from package overrdies.

Bug: 147113465
Test: N/A
Change-Id: I35c6fe418abb9bc562218444878188bc393725e5
2021-01-20 14:15:14 +00:00
satayev
5d37ff2d33 Merge "Refactor PlatformCompat and related files." 2021-01-20 14:13:45 +00:00
Galia Peycheva
c8a82f5ee5 Merge "Add blur feature to package manager" 2021-01-20 14:13:45 +00:00
Artur Satayev
5d640c39a3 Refactor PlatformCompat and related files.
- Fix java style
- Remove some code duplication
- Remove redundant throws declarations for unchecked exceptions
- Fix javadoc typos

Bug: 147113465
Test: N/A
Change-Id: I723ddf3184e2da77f157340c4ef18e9395b99e60
2021-01-20 11:21:40 +00:00
Galia Peycheva
f78234f112 Merge changes from topic "blur_system_api"
* changes:
  Make BackgroundBlurDrawable a SystemApi
  Make window background blurs SystemApi
  Add permission for blur SystemApi
2021-01-20 05:04:01 +00:00
Tiger Huang
d4391287d5 Merge "Add BEHAVIOR_DEFAULT for visual immersive mode" 2021-01-20 04:20:40 +00:00
Benjamin Schwartz
bded2c1344 Merge "Introduce PowerStatsInternal and replace PowerStatsHalWrapper usage" 2021-01-19 21:39:59 +00:00
Treehugger Robot
1151863969 Merge "Fixed Handler Leak on WrapperInit" am: 9c7e15ab31 am: d723dd9191 am: 5a1e5ac1ff
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1495716

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8097c4fc518a6920026c2db5ea902ae21e1172a1
2021-01-19 19:13:23 +00:00
Treehugger Robot
5a1e5ac1ff Merge "Fixed Handler Leak on WrapperInit" am: 9c7e15ab31 am: d723dd9191
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1495716

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I14173b39846f2ef92698731b48dd4dd79d361b97
2021-01-19 19:12:06 +00:00
Miranda Kephart
302cd6f87b Merge "Add shared transitions from screenshot to markup" 2021-01-19 18:38:47 +00:00
Michael Wachenschwanz
605ac95a04 Introduce PowerStatsInternal and replace PowerStatsHalWrapper usage
PowerStatsService will handle PowerStatsHal queries, PowerStatsInternal
will provide the LocalService for querying PowerStatsHal derived data
from other System services.

Bug: 173077356
Test: atest FrameworksCoreTests:com.android.internal.power.MeasuredEnergyStatsTest
Test: atest com.android.server.powerstats.PowerStatsServiceTest

Change-Id: Ibc0165a44ffdbbcc9328c250f1dca3d29616c766
2021-01-19 10:21:58 -08:00
Treehugger Robot
9c7e15ab31 Merge "Fixed Handler Leak on WrapperInit" 2021-01-19 18:05:04 +00:00
Galia Peycheva
36ba33e66a Add blur feature to package manager
Bug: 177523043
Bug: 177524486
Test: adb shell pm list features
Change-Id: Ibda2d51e6517753148609f5ae2e1a7e077b89b1e
2021-01-19 17:07:11 +01:00
Alison Cichowlas
b9ba83d235 Correct duplicate log ID.
Test: atest ChooserActivityTest
Change-Id: I9ad50e48ab381d64f9a7beb18a71a22d879bde5f
2021-01-19 16:05:35 +00:00
Rubin Xu
5eab037be5 Option to skip profile password requirement during password enrolment
Add a new extra for ACTION_SET_NEW_PARENT_PROFILE_PASSWORD which will
allow the flow to not enforce password requirement coming from the
profile side. This is to enable better password enrolment flow when
the DPC is guiding the user to enrol both a personal and work lock.

Bug: 169832516
Test: atest FrameworksServicesTests:DevicePolicyManagerTest
Test: m RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.password
Change-Id: Idb33418f3e532dffc96ccb907f5cae0b6185173e
2021-01-19 15:36:05 +00:00
Tiger Huang
d878909a9b Add BEHAVIOR_DEFAULT for visual immersive mode
BEHAVIOR_DEFAULT lets the user can use single gesture to navigate while
system bars are hidden in gesture navigation mode. The user doesn't
need to make navigation bar visible before performing navigation.

BEHAVIOR_DEFAULT will be the default behavior, which means if there is
no system bar behavior (or any legacy sysui flag about immersive)
specified, the behavior will be BEHAVIOR_DEFAULT instead of
BEHAVIOR_SHOW_BARS_BY_TOUCH.

BEHAVIOR_SHOW_BARS_BY_TOUCH and BEHAVIOR_SHOW_BARS_BY_SWIPE are
deprecated. Their behavior is equivalent to BEHAVIOR_DEFAULT now. The
logic about HideNavInputEventReceiver is removed.

Bug: 168913586
Test: atest WindowInsetsControllerTests ViewRootImplTest
            DisplayPolicyTests CommandQueueTest
            LightsOutNotifControllerTest RegisterStatusBarResultTest
Change-Id: Ic818e323abbb38b57bef9fc36fb1afef2a007f1b
2021-01-19 23:33:21 +08:00
Galia Peycheva
42f19b6163 Make BackgroundBlurDrawable a SystemApi
Bug: 177524486
Test: check that using the drawable in the PermissionController works

Change-Id: I0b881ec6e9a41c5aed3ca17589a6d66ced0539bf
2021-01-19 13:50:53 +01:00
Galia Peycheva
e463ad6d1b Make window background blurs SystemApi
This CL makes windowBackgroundBlurEnabled, windowBackgroundBlurRadius
and WM.LP backgroundBlurRadius SystemApis to be used for bross-app blur.

WM.LP.backgroundBlurRadius is protected via a
Manifest.permission.USE_BACKGROUND_BLUR, which is checked both in the
system server and in SurfaceFlinger.

This CL also mokes WM.LP.FLAG_BLUR_BEHIND a SystemApi. It has been a
public API since 2009 and was deprected in 2011. It has been a no-op
ever since that. We are removing it from being a public api and will
use it as a system api in S

Bug: 167166562
Bug: 177524486
Test: manual - use PermissionController dialog to check SystemApis work
Change-Id: Icf98c3607b7d7ccdfb67b279e9fc5a83eba14204
2021-01-19 13:50:36 +01:00
Wilson Wu
0a32fd21ef Make IInputMethodManager to oneway (9/N)
Apply following methods to IVoidResultCallback to emulate
current behavior before we change them to one-way.

-. showInputMethodPickerFromClient
-. showInputMethodPickerFromSystem
-. showInputMethodAndSubtypeEnablerFromClient
-. reportActivityView

Bug: 163453493
Test: Manual test with keyboard
Test: atest CtsInputMethodTestCases
Test: atest CtsWindowManagerDeviceTestCases:ActivityViewTest
Change-Id: Id516fd1c961f43ac3e139c88d7ed004c188d458b
2021-01-19 11:37:03 +08:00
Treehugger Robot
eb716a055c Merge "Use API RouteInfo constructor in VpnConfig" am: 78426b28cc am: 5f2a3aca17 am: 2789600fdb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552496

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ibc64e9dfa4dd56ef817469e2ecffcb662b64c8de
2021-01-18 06:32:54 +00:00
Treehugger Robot
2789600fdb Merge "Use API RouteInfo constructor in VpnConfig" am: 78426b28cc am: 5f2a3aca17
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552496

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ib005c7b3c640f88e89868ff334aae5dcfd7f3852
2021-01-18 06:04:45 +00:00
Yunfan Chen
93d1656697 Merge "Ensure notifying when only caption insets changed" 2021-01-18 05:24:47 +00:00