Commit Graph

110929 Commits

Author SHA1 Message Date
Charles Chen
ae905ec585 Merge "Fix lock contention in ResourcesManager" 2020-08-25 01:26:30 +00:00
TreeHugger Robot
adf80b4adc Merge "fix app prediction service doesn't clean-up properly." into rvc-qpr-dev am: 4cb7d8c878 am: e548482d8d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12221409

Change-Id: I5ec77ed5785cd9ac1d2be7007bdff9cad94b0fb3
2020-08-24 21:17:55 +00:00
Neil Fuller
1bb318e04e Merge "Implement user-scoped geolocation configuration" 2020-08-24 19:47:49 +00:00
TreeHugger Robot
e548482d8d Merge "fix app prediction service doesn't clean-up properly." into rvc-qpr-dev am: 4cb7d8c878
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12221409

Change-Id: I880aa857e53bc499837b8cb2c1eeff84137a55be
2020-08-24 18:57:50 +00:00
TreeHugger Robot
4cb7d8c878 Merge "fix app prediction service doesn't clean-up properly." into rvc-qpr-dev 2020-08-24 18:27:26 +00:00
TreeHugger Robot
8940f10402 Merge "Add a SettingsProvider key for Adaptive connectivity" into rvc-qpr-dev am: b0df580193
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12383606

Change-Id: I7421c1f07d89d1b7c5371c83ed8a94f7f4ae9c71
2020-08-24 16:05:11 +00:00
Neil Fuller
a223581eee Implement user-scoped geolocation configuration
Implement user-scoped geolocation configuration / behavior.

The main changes:

1) For simplicity, configuration change listener is no longer passed the
latest config. It is left to the listener to request the latest config.
This removes some of the previous complexity that required a SparseArray
to track listeners by userId.

2) The Callback implementation is now responsible for listening for
configuration / user changes and invoking a listener (which will invoke
other listeners). This is to try to have one class know all the various
settings that affect auto time / geolocation detection behavior, which
has become more complicated with the user-scoped geolocation config. The
TimeZoneDetectorInternal has some listener methods added in preparation
for later steps.

3) The new "geolocation detection enabled" setting is added. This allows
users to selectively disable geolocation time zone detection
independently of the location toggle.

4) The TimeZoneConfiguration now carries the ID of the user it is for,
since it now contains user-specific state.

5) Internally, the TimeZoneConfiguration is replaced by the
ConfigurationInternal class, which includes all properties (not just
user visible settings) that influence time zone behavior on the device.
The ConfigurationInternal generates the TimeZoneCapabilities and
TimeZoneConfiguration.

6) In a change from the initial behavior, any previously received
geolocation suggestion is cleared if geolocation detection is turned
off (or the current user switches to one that has it turned off), and
suggestions received when geolocation detection is off are ignored.
This is trying to be careful to avoid caching the geolocation timezone
if the user has signalled they don't want their device to use it.

Test: atest services/tests/servicestests/src/com/android/server/timezonedetector
Test: atest core/tests/coretests/src/android/app/timezonedetector
Bug: 149014708
Change-Id: Ieac9f8f646e16edcb8b6ea6c8749e45761898ac1
2020-08-24 15:42:00 +01:00
Siyamed Sinir
bc372d0352 Merge "Remove clarabayarri from text OWNERS" am: 3fe6523d2f am: 153ae28af7 am: c7790b29ad am: 0e72570b88 am: 3d690999c3
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406974

Change-Id: Ifff11b7d1ff7487e15a4c3b62fef285be6928f0c
2020-08-24 12:38:45 +00:00
Louis Pullen-Freilich
b7a28dd234 Merge "Adds lpf@ to preference owners" am: 0c66523a48 am: 8a42ceda65 am: 0c311b4d8a am: d839a65584 am: 0fc494407f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406973

Change-Id: I72b1234cfb4200e839cc810cee4b42884b1852b1
2020-08-24 12:38:30 +00:00
Arc Wang
d631c648b3 Add a SettingsProvider key for Adaptive connectivity
Adaptive connectivity is a feature to manage 5G connectivity
for better battery life.

Bug: 162871294
Test: compile
Change-Id: I719e44a29a54ee886e5d3a7180fd3ad9a7dff599
Merged-In: I719e44a29a54ee886e5d3a7180fd3ad9a7dff599
2020-08-24 20:26:16 +08:00
Siyamed Sinir
3d690999c3 Merge "Remove clarabayarri from text OWNERS" am: 3fe6523d2f am: 153ae28af7 am: c7790b29ad am: 0e72570b88
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406974

Change-Id: Iecaaa780ba827ff6fc197e8b59f14169a63b16d0
2020-08-24 12:21:50 +00:00
Louis Pullen-Freilich
0fc494407f Merge "Adds lpf@ to preference owners" am: 0c66523a48 am: 8a42ceda65 am: 0c311b4d8a am: d839a65584
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406973

Change-Id: I85595cb921655173aba248f7dbb07779dbb4a665
2020-08-24 12:21:38 +00:00
Siyamed Sinir
0e72570b88 Merge "Remove clarabayarri from text OWNERS" am: 3fe6523d2f am: 153ae28af7 am: c7790b29ad
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406974

Change-Id: I042469b4aef280d955fc8199751b352fceb00a65
2020-08-24 11:53:41 +00:00
Louis Pullen-Freilich
d839a65584 Merge "Adds lpf@ to preference owners" am: 0c66523a48 am: 8a42ceda65 am: 0c311b4d8a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406973

Change-Id: Ic51084fd57a97d4e065a49434a9357d73ec56db7
2020-08-24 11:53:30 +00:00
Siyamed Sinir
c7790b29ad Merge "Remove clarabayarri from text OWNERS" am: 3fe6523d2f am: 153ae28af7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406974

Change-Id: I36b8f7edad6cd11e54c89c8adcc43177710d8fac
2020-08-24 11:30:56 +00:00
Louis Pullen-Freilich
0c311b4d8a Merge "Adds lpf@ to preference owners" am: 0c66523a48 am: 8a42ceda65
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1406973

Change-Id: I496eeb2ed6dc00f07bc4948af56fcfa339cf21dc
2020-08-24 11:30:34 +00:00
Charles Chen
2de5510bdf Fix lock contention in ResourcesManager
1. Scope dowm synchronized block to mAdjustedDisplays put and get
2. Use SoftReference instead of WeakReference because
   display's weak reference is cleared after getAdjustedDisplay
   returned and the cache didn't take effects previously.

fixes: 162445376
Test: ResourcesManagerPerfTest
Before:
    getDisplayMetrics_median: 3413
    getDisplayMetrics_mean: 3439
    getDisplayMetrics_min: 3364
    getDisplayMetrics_standardDeviation: 107
After:
    getDisplayMetrics_median: 3048
    getDisplayMetrics_mean: 3096
    getDisplayMetrics_min: 2999
    getDisplayMetrics_standardDeviation: 134

Change-Id: I8a5c3ba960c8231aee78b0e7fb958bf6845d5bb5
2020-08-24 16:30:48 +08:00
TreeHugger Robot
4514df4f1a Merge "Fixes activity didn't receive windowing mode change while exitPip" 2020-08-24 02:32:32 +00:00
Songchun Fan
374f7654df [IncrementalService] getLoadingProgress (v1)
This is to unblock Launcher's work on progress ring. Currently it uses
incfs getFilledBlocks(). Will switch to the new incfs progress reporting
API once it is ready.

Test: unit test
Test: adb shell dumpsys incremental
BUG: 165799231
Change-Id: Icd68124806454f888826294da36f109bca9771ac
2020-08-22 04:17:02 +00:00
TreeHugger Robot
9b489d77fc Merge "Add dump of InputConsumer to ViewRootImpl" 2020-08-21 23:03:35 +00:00
Kevin Hufnagle
55d5e6f80e docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006 am: 53f6fe0a82 am: 75e21ea878 am: 0d13b1b5cf
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: Ib592b19691b4dff48e19ef198fea2b609e7a68f9
2020-08-21 21:47:51 +00:00
Kevin Hufnagle
0d13b1b5cf docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006 am: 53f6fe0a82 am: 75e21ea878
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: I76f075cb854e4137f44cb35c911a064a7ed60660
2020-08-21 21:35:07 +00:00
Kevin Hufnagle
8293d8aba7 docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006 am: 53f6fe0a82
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: I74bc5add5347f1f77d77c54c1c1c7cbf4d85243c
2020-08-21 21:04:04 +00:00
Kevin Hufnagle
75e21ea878 docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006 am: 53f6fe0a82
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: I88a67e4f78f0f9081499c7e50e3c73a31d55ddf2
2020-08-21 21:03:46 +00:00
Kevin Hufnagle
d3093ce956 docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: I0a9b0550c4f129e9f8839f149b704b956cee4451
2020-08-21 20:48:15 +00:00
Kevin Hufnagle
53f6fe0a82 docs: Fix note about new intent action changes coming with Android 11. am: e69b8a9006
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12418304

Change-Id: I90566db73bb86ec900ae8246dd8f504ad3adb104
2020-08-21 20:48:04 +00:00
Siarhei Vishniakou
0c2a482edb Add dump of InputConsumer to ViewRootImpl
To further debug ANR issues, add dump of InputConsumer-related objects
to ViewRootImpl

Example dump:

      android.view.ViewRootImpl$WindowInputEventReceiver
       mInputChannel: 25697fd com.google.android.pixel.setupwizard/com.google.android.pixel.setupwizard.user.WelcomeActivity (client)
       mSeqMap: {}
       mReceiverPtr:
        mInputConsumer:
          mResampleTouch = true
          mChannel = 25697fd com.google.android.pixel.setupwizard/com.google.android.pixel.setupwizard.user.WelcomeActivity (client)
          mMsgDeferred: false
          Batches:
              <empty>
          mSeqChains:
              <empty>

        mBatchedInputEventPending: false
        mFinishQueue:
          <empty>

    Choreographer:
      mFrameScheduled=false
      mLastFrameTime=1625545 (8 ms ago)

Bug: 160561987
Test: adb shell dumpsys activity -v all | grep -i input -C 50
Test: adb shell dumpsys activity service SystemUIService | grep -i EventReceiver -C 20
Change-Id: I99807c264ced8eb939b90a30e2ff91775fbdec40
2020-08-21 14:37:04 -05:00
Siyamed Sinir
3fe6523d2f Merge "Remove clarabayarri from text OWNERS" 2020-08-21 19:08:49 +00:00
TreeHugger Robot
b1b4752718 Merge "Fix showing keyboard without editor focused in some cases (2/2)" 2020-08-21 17:09:08 +00:00
Clara Bayarri
0ac2e4ac31 Remove clarabayarri from text OWNERS
Change-Id: Ic67b5937d150096fddfe839d3406b29ba4bcb3a7
2020-08-21 17:07:57 +00:00
Louis Pullen-Freilich
76ec215c01 Adds lpf@ to preference owners
Change-Id: I11c74417090ce3b4da8c26512425df624a3932b9
2020-08-21 17:05:34 +00:00
Ming-Shin Lu
d5ae401390 Fix showing keyboard without editor focused in some cases (2/2)
As CL[1] mentioned issue symptom, we also need to remove
STATE_ALWAYS_VISIBLE in EditTextPreference
and using new WindowInsets API to show soft-keyboard, to prevent the
keyboard may be shown without focusing editor case.

[1]: I37ae6e30d1de581ba15131c2a90396b3a522a4d6

Fix: 165910518
Test: atest CtsInputMethodTestCases
Test: manual as issue steps
1. Enter Dialer-> Menu -> Settings-> calling accounts -> Fixed Dialing Numbers
2. Tap change pin2 code, input old pin2 -> pressing ok button
3. Check if password keyboard shown

Change-Id: I763838fb7b887e09b46b1fb2360a515b77de8dd4
2020-08-22 00:33:46 +08:00
Treehugger Robot
bd04e45980 Merge "Add systrace tag for system property" 2020-08-21 09:33:53 +00:00
wilsonshih
283da3bf5f Fixes activity didn't receive windowing mode change while exitPip
When user dismiss pip, WindowOrganizerController#applyChanges would
first try to resize pinned task, this will cause the activity to do
ensureActivityConfiguration and which could trigger configuration
change or relaunch the client activity. However, the windowing mode was
not change yet, so the windowing mode change would be scheduled in
another configuration change to client. But since the windowing mode
is not public, client will treat there is difference so skip that
configuration. To ensure client receive windowing mode change, check it
before check configuration difference.
And in order to prevent the WindowState#reportResized send before
ActivityRelaunchItem send to client, skip resize if we already know
that activity is going to relaunch.

Bug: 165051679
Test: atest ActivityLifecyclePipTests ActivityLifecycleSplitScreenTests
ActivityLifecycleTopResumedStateTests PinnedStackTests SplitScreenTests
ActivityLifecycleKeyguardTests

Change-Id: I7b96bbcf1a71ff75751e14db44c03261862bc857
2020-08-21 05:10:11 +00:00
Darryl Johnson
48f430566d Merge "Don't override config of display contexts with activity display." 2020-08-20 21:47:53 +00:00
Philip P. Moltmann
67cfa22571 Add app-ops for camera/mic use during phone call am: 732608a6be
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12396940

Change-Id: If8cbb6d6535dc1858e475d59ad282b89560c7de7
2020-08-20 19:50:24 +00:00
Hall Liu
99f3dc8aee Merge "Expose onEmergencyNumberListChanged, semantics change" 2020-08-20 19:29:58 +00:00
Kevin Hufnagle
e69b8a9006 docs: Fix note about new intent action changes coming with Android 11.
Bug: 155091482
Change-Id: I3dfeb333cbe95880142ed97d0d50fd9f85c52f50
Test: Documentation changes - no test necessary
2020-08-20 18:48:17 +00:00
Darryl L Johnson
3c0078e80f Don't override config of display contexts with activity display.
This change migrates the previous usages of
ResourcesManager#getResources() from using the display id of expected
resources to an override display ID which will override the display
properties from the parent token resources. This ensures that all
contexts derived from a display context keep the overrides for their
intended display.

This also changes the meaning of ResourcesKey#mOverrideConfiguration and
ResourcesKey#mDisplayId. Previously mDisplayId was used as both the
current display of the ResourcesKey and used to apply overrides
to mOverrideConfiguration. This made it unclear whether a particular key
should keep its display override when an activity changes display or
whether it should inherit the new display from the activity. Now the
display IDs and overrides are managed by the ActivityResources struct and the
ResourcesKey is expected to only contain the final display ID expected
for the resources in 'mDisplayId' and the final configuration that should
be applied to the global configuration in 'mOverrideConfiguration'.

Fixes: 153866583
Fixes: 156758475
Fixes: 163813210
Fixes: 163812902
Fixes: 163813227

Test: ActivityThreadTest
Test: ResourcesManagerTest
Test: AppConfigurationTests#testActivityContextDerivedDisplayContextOrientationWhenRotating

Change-Id: If93f98f93ee15b27d8c7292a2f830c2cc0f49277
2020-08-20 10:15:48 -07:00
Philip P. Moltmann
cd2fde9468 Merge "Add app-ops for camera/mic use during phone call" 2020-08-20 14:10:08 +00:00
Treehugger Robot
835ed973ec Merge "Update language to comply with Android's inclusive language guidance" am: 4983d13ccc am: 28a65b8942 am: 92876acc20 am: fdeef2b1ed am: 1a3ff01217
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1403549

Change-Id: I61d6b7591059e1c91d878d3c55d9a84d3bf3c800
2020-08-20 13:29:15 +00:00
Treehugger Robot
1a3ff01217 Merge "Update language to comply with Android's inclusive language guidance" am: 4983d13ccc am: 28a65b8942 am: 92876acc20 am: fdeef2b1ed
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1403549

Change-Id: I80116dde66a0aef45add805eb2e7ba5eeef04c4c
2020-08-20 13:13:48 +00:00
Treehugger Robot
fdeef2b1ed Merge "Update language to comply with Android's inclusive language guidance" am: 4983d13ccc am: 28a65b8942 am: 92876acc20
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1403549

Change-Id: I99915dd0ff99245aad2c31e2d0c0a7daa79f0b92
2020-08-20 13:02:46 +00:00
TreeHugger Robot
739663d450 Merge "Replace redundant error code with a specific one" 2020-08-20 12:59:20 +00:00
Treehugger Robot
92876acc20 Merge "Update language to comply with Android's inclusive language guidance" am: 4983d13ccc am: 28a65b8942
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1403549

Change-Id: I7c40c508a60dd793d0ffc3cd01ab0cc17345e759
2020-08-20 12:34:19 +00:00
Mark Renouf
9b93699911 Merge "Fix missing null check in collectRootScrollCaptureTargets" 2020-08-20 12:26:38 +00:00
Treehugger Robot
4983d13ccc Merge "Update language to comply with Android's inclusive language guidance" 2020-08-20 12:14:31 +00:00
Tiger Huang
606a45341b Merge "Refine system bar position restoring" into rvc-d1-dev am: 6383ac86ca
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12406774

Change-Id: I9b1e07559a3194b22d07d7b107d780abc4f1bcc9
2020-08-20 11:05:46 +00:00
lpeter
2736db57ff Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

Bug: 162536543
Test: Build pass and boot
Change-Id: I0a46d4366948addad629142157c361c7133179af
2020-08-20 18:00:49 +08:00
Chienyuan Huang
4e8bae8d7f Merge "Revert^2 "Add systrace tag for system property"" 2020-08-20 08:48:04 +00:00