Commit Graph

615375 Commits

Author SHA1 Message Date
Lorenzo Colitti
6731b9992f Merge "Generalize support for underlying networks." am: 72c26b883f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1513052

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia252eb29dbccb0105c3f4a46c7597abb56de0c21
2020-12-14 05:59:51 +00:00
Treehugger Robot
4fb275ef08 Merge "Fix a crash in eng builds" am: 0fc25a8693
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1527538

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I245a8498d89e73fefa448a23d71a30d3f34b56ca
2020-12-14 05:50:17 +00:00
Riddle Hsu
5c2c75eec6 Remove unnecessary lib from WmTests
Only one simple method of the lib is used, that doesn't need to
include the medium size lib.

Bug: 159102753
Test: TaskStackChangedListenerTest
Change-Id: I312c75a366bdfc5a9017c32443732b1ac96797ab
2020-12-14 05:38:20 +00:00
Riddle Hsu
0e08c81e98 Remove lock of getLockTaskModeState
The state field is declared as volatile. And the field is always
written on display thread without lock. So it is unnecessary to
lock the getter method.

Bug: 173467481
Test: CtsWindowManagerDeviceTestCases
Change-Id: I6324f6745fd849438b7b0d326bd63bd2d0580421
2020-12-14 05:34:41 +00:00
TreeHugger Robot
331168f15a Merge "Use LatencyTracker to log the time of recents animation" 2020-12-14 05:31:09 +00:00
Shawn Lin
31b71a0c7d Merge "Add a new method to notify system to detach the nav bar" 2020-12-14 05:29:33 +00:00
Wesley.CW Wang
43f10543e6 Extend Battery Defender strings chars limit
Bug: 174860445
Test: m -j40, make full ROM
Change-Id: Icd7dda8c0c2cc6dcc48f7c8bf1ff1b4e5d690adf
2020-12-14 05:22:57 +00:00
Lorenzo Colitti
72c26b883f Merge "Generalize support for underlying networks." 2020-12-14 05:19:49 +00:00
Treehugger Robot
0fc25a8693 Merge "Fix a crash in eng builds" 2020-12-14 05:17:15 +00:00
Roy Want
2aab670722 Merge "Adding setter and getters for setRttBurstSize() in RangingRequest (client)" 2020-12-14 05:13:40 +00:00
Chiachang Wang
ed4536c5ac Merge "Resolve UidRange dependency between NMS and CS module" am: c3806f72b7 am: d7795cd590 am: fced6020f8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1495869

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6c3474e6522fc67aec5333b323768692619019ee
2020-12-14 04:23:43 +00:00
Mehdi Alizadeh
9d36cc2280 Don't reset default launcher if the user is not loaded
If the user is not loaded in ShortcutService, there is no need to reset
the current default launcher. This is to prevent any unnecessary file IO
when the default launcher changes.

Bug: 173614832
Test: atest com.android.server.pm.ShortcutManagerTest1
            com.android.server.pm.ShortcutManagerTest2
            com.android.server.pm.ShortcutManagerTest3
            com.android.server.pm.ShortcutManagerTest4
            com.android.server.pm.ShortcutManagerTest5
            com.android.server.pm.ShortcutManagerTest6
            com.android.server.pm.ShortcutManagerTest7
            com.android.server.pm.ShortcutManagerTest8
            com.android.server.pm.ShortcutManagerTest9
            com.android.server.pm.ShortcutManagerTest10
            com.android.server.pm.ShortcutManagerTest11
      atest CtsShortcutHostTestCases
      atest CtsShortcutManagerTestCases
Change-Id: Ic3bbb0f7b4d308bddbff1d586a8700388f317f6b
2020-12-13 19:54:30 -08:00
Chiachang Wang
fced6020f8 Merge "Resolve UidRange dependency between NMS and CS module" am: c3806f72b7 am: d7795cd590
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1495869

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If34efef1e3b485de6c93f78c4401ea92fa8edfe4
2020-12-14 03:49:42 +00:00
Chiachang Wang
d7795cd590 Merge "Resolve UidRange dependency between NMS and CS module" am: c3806f72b7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1495869

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2e55c3c4bed3d71eb48242428c179809aae00a1f
2020-12-14 03:10:01 +00:00
Treehugger Robot
93746895e3 Merge "[Bugfix]audio:fix NPE when buildBluetoothRoutes" am: b801d3549f am: 62621db913 am: 0db017d837
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519791

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7c8eac7b3ad067e5fabd44a0ea26feddbecaee85
2020-12-14 03:01:09 +00:00
Chiachang Wang
c3806f72b7 Merge "Resolve UidRange dependency between NMS and CS module" 2020-12-14 02:55:41 +00:00
TreeHugger Robot
bf75b356ba Merge "Expose MediaExtractor entry point to MediaMetrics" 2020-12-14 02:40:08 +00:00
Kyunglyul Hyun
9f889ca4e6 MediaRouterService binds services when necessary
MediaRouterService maintained bindings to provider services
once those are established.

With this CL, it only binds services when there is a non-empty
discovery preference set by a foreground app or an app is casting.

This change may break output switcher, which enables transfer media
of background apps.

To alleviate that MediaRouter2Manager#startScan and #stopScan are added
so that system UI can force the service bind to the services and find
remote devices to cast.

Bug: 169575701
Bug: 172920557

Test: manually and CTS
Change-Id: I4a47fdb1c9fe05a04d26950485833c9cbfb91a69
2020-12-14 02:33:45 +00:00
Treehugger Robot
0db017d837 Merge "[Bugfix]audio:fix NPE when buildBluetoothRoutes" am: b801d3549f am: 62621db913
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519791

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8805f00edfc3f01e39703063bb3ae66b26f686e7
2020-12-14 02:23:39 +00:00
Treehugger Robot
62621db913 Merge "[Bugfix]audio:fix NPE when buildBluetoothRoutes" am: b801d3549f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519791

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I849ac5c7d88cbde748881d4aa85f5bacf9345d91
2020-12-14 01:46:14 +00:00
Treehugger Robot
b801d3549f Merge "[Bugfix]audio:fix NPE when buildBluetoothRoutes" 2020-12-14 01:33:36 +00:00
Hui Yu
7082941222 Merge "The ability to start FGS can be passed down by service binding." 2020-12-13 21:54:56 +00:00
Hui Yu
631f90a7b8 The ability to start FGS can be passed down by service binding.
1. Add field mAllowStartFgs in ProcessRecord to indicate this app can
start FGS.
2. mAllowStartFgs is true if the process has
  * any of these permissions: START_ACTIVITIES_FROM_BACKGROUND,
START_FOREGROUND_SERVICES_FROM_BACKGROUND, SYSTEM_ALERT_WINDOW
  * the process's uid is ROOT_UID, SYSTEM_UID, NFC_UID, SHELL_UID.
  * the process's proc state is higher or equals to
PROCESS_STATE_BOUND_FOREGROUND_SERVICE.
  * the process's uid is DeviceOwner, or allowlisted by
DeviceIdleController.
3. The mAllowStartFgs ability can be passed to another process by
service binding. Except if the binder is PROCESS_STATE_PERSISTENT, this
ability does not pass down.

Bug: 171305836
Test: atest cts/tests/app/src/android/app/cts/ActivityManagerFgsBgStartTest.java#testFgsBindingFlagNone

Change-Id: I20d977ce7ae65316cdec2cd0ef9cf9bafec2adbd
2020-12-13 10:26:12 -08:00
Stanislav Zholnin
96165b5983 Force sampling to always take all ops for the same package.
Bug:167579006

Test: manually verified
Change-Id: I3d86ec5fc8ad7ff5c6042caa7265647722bc62ac
2020-12-13 18:17:35 +00:00
Nicolas Geoffray
498aa12949 Remove FastNative annotations on synchronized methods.
FastNative doesn't work on synchronized methods.

Bug: 175016705
Test: 004-JniTest
Change-Id: I1e34c78a8438c67e5a1bedb83eb977389ee9a82d
Merged-In: I1e34c78a8438c67e5a1bedb83eb977389ee9a82d
(cherry picked from commit 7c4c101a7b)
2020-12-13 17:44:59 +00:00
TreeHugger Robot
bde6cfbd10 Merge "Clean up LetterboxTaskListerner and all related logic." 2020-12-13 17:36:25 +00:00
Mariia Sandrikova
2f37c38f33 Clean up LetterboxTaskListerner and all related logic.
This is the first step towards moving letterbox gravity logic from WM Shell to WM Core. It's important to do this even before the new implementation in WM Core is ready because surface repositioning in WM Shell causes visible flickering on rotation for all apps on devices with cutout.

Fix: 174632285
Bug: 175212232
Fix: 173440321
Test: atest WMShellUnitTests
Change-Id: I2b3706a1a46bb2c7ee4bb3789fb09b216e32f290
2020-12-13 15:17:11 +00:00
Chen Xu
1292b4a974 add permission check for exported activity
CaptivePortalLoginActivity is exported without any permission check
which has security concerns: The captive portal activity can be
tricked into making various carrier calls, including
resetAllCarrierActions.

Bug: 160871056
Test: Build
Change-Id: Ib7cc1ba4aca665bc94f8582de6bba7af252c481d
2020-12-13 14:12:15 +00:00
Chalard Jean
fb0ff9bbcf Fix a crash in eng builds
CAPTIVE_PORTAL is a CS-managed capability, and causes CS to log a wtf.
When this test is run on an eng build, this sends SIGSEGV to the test,
which is pretty difficult to debug.

Test: FrameworksNetTests NetworkStackTests
Change-Id: I72fc46a6daa4e886425b4dc967318cca9f1a5302
2020-12-13 23:02:08 +09:00
Trung Lam
3fdf3bad74 Merge "Fix issue with saving protos to disk during shutdown." into rvc-qpr-dev am: 0943ebe36d am: bcd913f08e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13203025

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I0d1e42ed49e7a4c7d5f22e36a67a8a811dc42162
2020-12-13 10:24:03 +00:00
Trung Lam
bcd913f08e Merge "Fix issue with saving protos to disk during shutdown." into rvc-qpr-dev am: 0943ebe36d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13203025

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I40be559cdb840da61cb008a849e9807c9475363b
2020-12-13 10:08:47 +00:00
Trung Lam
0943ebe36d Merge "Fix issue with saving protos to disk during shutdown." into rvc-qpr-dev 2020-12-13 09:56:40 +00:00
Jimmy Chen
3f8b46ebf8 wifi: create security type for Passpoint R1/R2 and R3
Bug: 162685856
Test: atest FrameworksWifiApiTests
Change-Id: I5cda53edd286787c97dfb09d047d582c97e8684b
2020-12-13 15:06:06 +08:00
Baligh Uddin
ff6457f822 Migrate to frameworks/proto_logging/stats
BUG: 175318992
Test: TH
Merged-In: Ia6463c8f6a801cd9db54afa30df0aa3f16b09891
Change-Id: I81324b83802dc2b06081600282bb73491f29473b
Exempt-From-Owner-Approval: cleanup CL
2020-12-12 17:42:07 +00:00
Lorenzo Colitti
6c01b8ebf7 Generalize support for underlying networks.
Currently, ConnectivityService assumes that only VPNs can have
underlying networks. Make the code decide this based only on the
return value of NetworkAgentInfo#supportsUnderlyingNetworks.
This allows non-VPN network types to support underlying networks
in the future.

This requires storing the original agent's capabilities in
NetworkAgentInfo so that applyUnderlyingCapabilities can mix in
the underlying network capabilities without overwriting the
capabilities of the network itself. Currently, the only
information that applyUnderlyingCapabilities takes from the
original agent's capabilities are the metered bit (stored in
NetworkAgentInfo#declaredMetered) and the transports (assumed to
be exactly {TRANSPORT_VPN}. Store the full capabilities instead.
This is more state than needed but it ensures that we do not need
to make any changes if in the future we want to propagate new
types of information from the underlying networks.

This should have no impact on current use cases (i.e., VPNs).

There is a change in ordering: in disconnectAndDestroyNetwork,
the new code propagates underlying network capabilities before
removing the network from LegacyTypeTracker, instead of after.

This is done to simplify the new code. When the new code
propagates underlying network capabilities in response to a
change for a particular network (e.g., connect, disconnect,
capabilities change), it only considers networks that have the
changed network as underlying. Because determining the
underlying networks requires knowing the default network,
the new code runs before the default network is changed and
LegacyTypeTracker is updated.

This shouldn't have app implications because the connectivity
broadcasts sent by LegacyTypeTracker and the callbacks cannot be
ordered, since they run on separate threads with unpredictable
delays. The capability change callbacks resulting from
propagation of underlying network capabilities were already
sent before the rematch, so the callbacks themselves are not
reordered in any way.

Bug: 173331190
Test: atest FrameworksNetTests \
            CtsNetTestCases:NetworkAgentTest \
	    CtsNetTestCases:Ikev2VpnTest \
	    CtsNetTestCases:VpnServiceTest \
	    CtsNetTestCases:android.net.cts.ConnectivityDiagnosticsManagerTest \
	    HostsideVpnTests com.android.server.connectivity.VpnTest
Change-Id: Ic5353a928a3a3541dcf953c35f47277c5e295db8
2020-12-13 00:10:56 +09:00
Siarhei Vishniakou
ce0f9518a8 Add attachinfo information to ViewRootImpl dump
Currently, we are dumping information on ViewRootImpl, but it doesn't
include some of the critical pieces. Add attachinfo information. Also,
attach a dump of a variable that determines whether the input events
will be dropped.

Example of newly added piece of dumpsys:

      mPausedForTransition=false
      ...
      mAttachInfo=       AttachInfo:
        mHasWindowFocus=true
        mWindowVisibility=0
        mInTouchMode=true
        mUnbufferedDispatchRequested=false

Bug: 173675649
Test: adb shell dumpsys activity -v all
Change-Id: I7b8801436f74a123bf96735de30b238146413545
2020-12-12 00:05:50 -10:00
Cole Faust
0223a5155f Merge "Add rotary highlight to switches" into rvc-qpr-dev am: c28fb42e29 am: 0142607742
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13211155

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4048b194e27fc11a81e184857fc3b92d15b9233e
2020-12-12 05:12:26 +00:00
Cole Faust
0142607742 Merge "Add rotary highlight to switches" into rvc-qpr-dev am: c28fb42e29
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13211155

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3c85c22df09b85c1c7a051fa750014354923ba7c
2020-12-12 04:52:44 +00:00
Jimmy Chen
5082458b5f Merge "softap: Add BAND_60GHZ to SoftApConfiguration" 2020-12-12 04:26:03 +00:00
Cole Faust
c28fb42e29 Merge "Add rotary highlight to switches" into rvc-qpr-dev 2020-12-12 04:11:13 +00:00
TreeHugger Robot
c3f64a3f97 Merge "Fix abnormal flicking when swiping up to exit OHM in 3-button mode" 2020-12-12 04:10:21 +00:00
TreeHugger Robot
cf4b64cf99 Merge "5-1/ Migrate CTS split screen testNonResizeable tests" 2020-12-12 03:04:09 +00:00
Treehugger Robot
431139218a Merge "Add missing IMF OWNERS" am: 4e3959e571 am: 30497d0911 am: 03ced7e52e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1525813

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5896f244b5d601ceec3da6d25cc2a1b633ff4f55
2020-12-12 02:54:04 +00:00
TreeHugger Robot
8920286cab Merge changes I3ad8bfec,I61902102
* changes:
  Canoncial IME Target (2/N)
  Canoncial IME Target (1/N)
2020-12-12 02:36:18 +00:00
TreeHugger Robot
0e097726f0 Merge "Allow ShortcutPackage#findAll to return cached shortcuts." 2020-12-12 02:30:15 +00:00
Eric Jeong
cbaf2ac108 Send DROPBOX_ENTRY_ADDED to all users
- DROPBOX_ENTRY_ADDED is sent to the system user.
- In headless system user, the current user could not be the system
user.
- This CL make it broadcasted to all interested receivers.

Bug: 158246058
Test: atest
CtsAppExitTestCases: android.app.cts.ActivityManagerAppExitInfoTest#testAnr
Change-Id: I897782a809ef5a115c536b03348296bdc4166630
2020-12-11 18:26:00 -08:00
TreeHugger Robot
7e05d5ef24 Merge "MediaMetadataRetriever: Fix null pointer exception" 2020-12-12 02:14:45 +00:00
Treehugger Robot
03ced7e52e Merge "Add missing IMF OWNERS" am: 4e3959e571 am: 30497d0911
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1525813

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3534455778648e6be10ffedbd2d692656d88d318
2020-12-12 02:14:04 +00:00
TreeHugger Robot
e5ade59a8c Merge "[am/SettingsProvider] use ForUser method to get AnrShowBackground Settings" 2020-12-12 02:12:32 +00:00
Nader Jawad
8b5c9c6061 Added View#setRenderEffect API
Added View API to configure RenderEffect on the underlying
RenderNode

Bug: 159712515
Test: Added CtsUiRenderingTestCase
Change-Id: Ic64009ac79927d61c7c1f63306ced3da18fce1da
2020-12-11 17:55:17 -08:00