Commit Graph

15256 Commits

Author SHA1 Message Date
Chiachang Wang
0930c03c9e Merge "[IT04] Add uid as parameter of interfaceClassDataActivityChanged" am: baef452e38 am: 04aa5eac85 am: a817ecd4b5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1523339

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ieafdf569c13b1421c18fa3086827e6e432b498d7
2020-12-23 07:31:25 +00:00
Chiachang Wang
a817ecd4b5 Merge "[IT04] Add uid as parameter of interfaceClassDataActivityChanged" am: baef452e38 am: 04aa5eac85
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1523339

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3dea98c80dd4d6f29739b26cf120957c58364445
2020-12-23 06:49:23 +00:00
Chiachang Wang
baef452e38 Merge "[IT04] Add uid as parameter of interfaceClassDataActivityChanged" 2020-12-23 05:20:33 +00:00
TreeHugger Robot
a52a79f7dd Merge "Make IInputMethodManager to oneway (7/N)" 2020-12-23 04:40:21 +00:00
TreeHugger Robot
9df82ca4cc Merge "Make IInputMethodManager to oneway (6/N)" 2020-12-23 03:52:54 +00:00
Wilson Wu
4a820ccc41 Make IInputMethodManager to oneway (7/N)
1. Create InputMethodInfoList result callback and apply it to :
   -. getInputMethodList
   -. getEnabledInputMethodList

2. Apply IntResultCallback to getInputMethodWindowVisibleHeight

Bug: 163453493
Test: Manual test with keyboard
Test: atest CtsInputMethodTestCases
Change-Id: Iaa63e01453da4ff0e3f446eac036b3be3180cb73
2020-12-23 10:27:05 +08:00
Remi NGUYEN VAN
23f93322c2 Merge "Split NetworkUtils and NetworkUtilsInternal" am: 3ed4fd3a89 am: 635d60201d am: edc6b0fb67
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1513140

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ief9d6a1fae360dbe1c43d5d6bac4dad5850c004b
2020-12-23 02:22:35 +00:00
Remi NGUYEN VAN
edc6b0fb67 Merge "Split NetworkUtils and NetworkUtilsInternal" am: 3ed4fd3a89 am: 635d60201d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1513140

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7b2eae7f9988ae8fa8c858709cafc17c1420f4b7
2020-12-23 02:07:05 +00:00
Remi NGUYEN VAN
3ed4fd3a89 Merge "Split NetworkUtils and NetworkUtilsInternal" 2020-12-23 01:19:27 +00:00
Treehugger Robot
137003fd24 Merge "Add owner to codegen annotations" am: 7765329813 am: e897f5f8d6 am: ea70d5adc2
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1530761

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9154535efa649300ee1b7a27e7739f24cf037b5b
2020-12-23 00:01:23 +00:00
Treehugger Robot
ea70d5adc2 Merge "Add owner to codegen annotations" am: 7765329813 am: e897f5f8d6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1530761

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie4370f8059802250c5bd9112a10573effba8551e
2020-12-22 23:23:24 +00:00
Treehugger Robot
7765329813 Merge "Add owner to codegen annotations" 2020-12-22 22:16:51 +00:00
Benjamin Schwartz
f17961cdd3 Merge "KernelWakelockReader: provide class level lock when updates staleStats" am: b9f60a53c3 am: ec13727383 am: 7805396ee6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1534034

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4ef1ab620b8a56e62c295d081f714de208d9fa57
2020-12-22 17:39:58 +00:00
Benjamin Schwartz
7805396ee6 Merge "KernelWakelockReader: provide class level lock when updates staleStats" am: b9f60a53c3 am: ec13727383
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1534034

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I32722ae3a7f5fbde2aa7d42402f8f2d670423f4b
2020-12-22 17:38:56 +00:00
Wilson Wu
38fd020616 Make IInputMethodManager to oneway (6/N)
Create InputMethodSubtype and InputMethodSubtypeList
result callback and apply it to :

-. getLastInputMethodSubtype
-. getCurrentInputMethodSubtype
-. getEnabledInputMethodSubtypeList

Bug: 163453493
Test: Manual test with keyboard
Test: atest CtsInputMethodTestCases
Change-Id: I646ef4ae0570aae1812ea267f309441fdec6938d
2020-12-22 10:56:18 +08:00
Chiachang Wang
9c133bc4e9 [IT04] Add uid as parameter of interfaceClassDataActivityChanged
Add uid into interfaceClassDataActivityChanged in
INetworkManagementEventObserver. This helps the listeners to use
BaseNetworkObserver to listen for target evnets instead of using
whole INetdUnsolicitedEventListener with no-op in other event
that listeners do not care about.

Bug: 170598012
Test: m ; atest FrameworksNetTests
Change-Id: I2a42a522c2ff9b1e0be88261a8574bb7f5292fa6
2020-12-22 08:39:22 +08:00
Michael Sun
5886ede607 KernelWakelockReader: provide class level lock when updates staleStats
As the wakelock version number is defined as static to provide
consistent versioning across objects, class level static lock should be
implemented to prevent racing conditions.

To trigger the racing condition, update statsd's stats pulling logic
locally to repeatably requesting wakelock stats then wakeup the phone
to trigger BatteryStats update routine. The racing condition is 100%
reproducible under the setup. The patch has been verified with the
setup, and the racing is no longer seen. See more reproduce details in
the linked bug.

Bug: 173539101
Test: manual
Change-Id: I386afa2f2ecd8678e71ece978da4a9950b21ca4d
2020-12-21 18:09:04 +00:00
Jeff Sharkey
ea470d5ca8 Merge changes from topic "dec16"
* changes:
  Enable binary XML by default.
  Prepare for binary XML pivot.
  Migrate SettingsProvider to support typed XML.
2020-12-20 18:22:30 +00:00
TreeHugger Robot
026102b5c8 Merge "Add SystemBatteryConsumer for the Bluetooth drain type" 2020-12-19 07:36:44 +00:00
Dmitri Plotnikov
8677b4eb5b Add SystemBatteryConsumer for the Bluetooth drain type
Bug: 175644968
Test: mp :BatteryStatsViewer && adb shell am start -n com.android.frameworks.core.batterystatsviewer/.BatteryStatsViewerActivity

Change-Id: I2adde65a63faf18f0120f281ab1fcd5373f25091
2020-12-18 18:10:00 -08:00
Alison Cichowlas
dc70bd944e Merge "Fix sharing shortcuts not showing for Work Profile." into rvc-qpr-dev am: ac9d6f53da
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13230685

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I141425524486e6a377b6be1062a17b0df13388d0
2020-12-18 00:34:12 +00:00
Darryl Johnson
c9e9058347 Revert "Use eBPF-based time-in-state monitoring for groups of threads"
This reverts commit a7b599b824.

Reason for revert: Possible cause of b/175685062

Change-Id: If9a4592fa1c8e4c97ae187e45b509c3753d2f47e
2020-12-17 14:48:39 -08:00
TreeHugger Robot
25d4114431 Merge "SyncPointerCapture (7/n): Clean up unused code from old Pointer Capture" 2020-12-17 18:06:02 +00:00
Jeff Sharkey
e09d74c644 Prepare for binary XML pivot.
As part of preparing to enable the new binary XML wire format across
the device, we ran a large suite of unit tests which uncovered a
handful of bugs where client code was assuming that the serializer
would create TEXT tokens for newlines between tags.

Also relaxes all binary XML classes to accept either "UTF-8" or
"utf-8" as the encoding name.  Slight bug fixes to clear names, text,
and attributes for each event to match XmlPullParser documentation.

Fixes for existing unit tests that were assuming human-readable XML,
or assuming that the serialization would perform UTF-8 validation.

Bug: 171832118
Test: atest FrameworksServicesTests
Change-Id: I841fe41e4967b36ab17551294ae0f42fb87a8e71
2020-12-17 08:16:06 -07:00
Treehugger Robot
ccd634ec0c Merge "Make a copy of libcore.util.ArraysUtils in framework" am: f35963cb77 am: acd5ae1807
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1531681

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I0232dc3e89ca638cf5097888946f7f70b3f116d1
2020-12-17 11:10:44 +00:00
Adam Bookatz
b406489702 Merge "OWNERS file for internal/power" 2020-12-17 05:37:26 +00:00
TreeHugger Robot
957b14994d Merge "Add "modeled" power components" 2020-12-17 04:03:13 +00:00
Victor Chang
63c5fe5d33 Merge "Make a copy of libcore.util.ArraysUtils in framework" 2020-12-17 02:25:00 +00:00
TreeHugger Robot
0aaf18c6a9 Merge "Screenshot to share sheet shared element transition." 2020-12-17 02:04:23 +00:00
Adam Bookatz
f3b0d892c3 Merge "BatteryStatsImpl uid blaming for measured energy data" 2020-12-17 00:37:17 +00:00
Victor Chang
37c6b6deeb Make a copy of libcore.util.ArraysUtils in framework
It helps remove it from the @CorePlatformApi

Bug: 154796679
Test: ArrayUtilsTest
Merged-In: I0c8f194a74a16b2cc46f9eea4571d5fb674fbc28
Change-Id: I0c8f194a74a16b2cc46f9eea4571d5fb674fbc28
2020-12-17 00:07:23 +00:00
Adam Bookatz
a5dec0da4d OWNERS file for internal/power
Not in AOSP since the directory doesn't exist there yet.

Test: N/A
Change-Id: I7a04ae0af3ed4a55aa7e25c6fbf5e827a6368ec4
2020-12-16 15:52:24 -08:00
Victor Chang
198ced861a Make a copy of libcore.util.ArraysUtils in framework
It helps remove it from the @CorePlatformApi

Bug: 154796679
Test: ArrayUtilsTest
Change-Id: I0c8f194a74a16b2cc46f9eea4571d5fb674fbc28
2020-12-16 23:50:30 +00:00
Jon Miranda
92dfd67351 Screenshot to share sheet shared element transition.
Switching the share action to a Supplier interface allows us to
maintain the current code style, while ensuring that the
APIs required to start the transition are called when the
share chip is pressed.

Bug: 174811491
Test: manual

Change-Id: I201b82eaea650fcef23909212385fd6d56831429
2020-12-16 23:40:29 +00:00
Dmitri Plotnikov
cd6147bea9 Add "modeled" power components
Modeled power components are computed without regard
for power measured with ODPM/rails.

The purpose of this is mostly to support testing
of power models themselves.

Bug: 175644968
Test: mp :BatteryStatsViewer && adb shell am start -n com.android.frameworks.core.batterystatsviewer/.BatteryStatsViewerActivity

Change-Id: Icca6fe6954776baed48b593017abd8c9bab4dfb7
2020-12-16 13:07:04 -08:00
Mark Renouf
b37c18a5f9 Merge "Fix restore of RecyclerView scroll position" 2020-12-16 20:58:45 +00:00
Adam Bookatz
f53dedb883 BatteryStatsImpl uid blaming for measured energy data
Adds support for blaming measured energy (rail) data on individual uids
starting with display.

1. Display measured energy data is apportioned to apps.
This is based on their relative foreground activity time and PROCESS_STATE_TOP
time, in accordance with the current BatteryStatsHelper smearing algorithm.

2. Infrastructure is in place for additional energy rails
to do likewise.

3. Fixes a bug in Bluetooth activity data not being reset properly

4. Fixes a bug in that resets didn't handle external data properly

Test: atest FrameworksServicesTests:com.android.server.am.MeasuredEnergySnapshotTest \
            FrameworksCoreTests:com.android.internal.power.MeasuredEnergyStatsTest \
            FrameworksCoreTests:com.android.internal.os.BatteryStatsNoteTest#testUpdateDisplayEnergyLocked

Bug: 174818228
Bug: 174818483
Bug: 174818545
Bug: 173652857
Change-Id: Ibade3689ad7c3c22e181c8086df25c203fe0ad6b
2020-12-16 12:32:59 -08:00
Prabir Pradhan
a26dd05602 SyncPointerCapture (7/n): Clean up unused code from old Pointer Capture
After the pipeline changes to Pointer Capture, this CL cleans up the
following:
- The old way of notifying windows of Pointer Capture
(IWindow::dispatchPointerCaptureChanged) is removed.
- Tracking Pointer Capture in WindowManagerService is removed.

Bug: 141749603
Test: manual, flash crosshatch, pointer capture works.
Change-Id: I5bbcef42fe8d0d93a64a4a411b1d493fcb800f92
2020-12-16 19:34:07 +00:00
TreeHugger Robot
8068b16f2f Merge "Move NUM_GPS_SIGNAL_QUALITY_LEVELS to GnssSignalQuality" 2020-12-16 18:58:25 +00:00
TreeHugger Robot
71a741594f Merge "Add InputConnection#performSpellCheck()." 2020-12-16 10:54:27 +00:00
Wilson Wu
0e75d9e4dd Merge "Make IInputMethodManager to oneway (5/N)" 2020-12-16 09:33:42 +00:00
Mark Renouf
d184971cce Fix restore of RecyclerView scroll position
Always subtract a delta to return to the origin.

Bug: 175740554
Fix: 175740554
Test: manual
Change-Id: I2bbce8f12eed34f2fe524784ea53cf42499ab690
2020-12-16 02:16:56 -05:00
Kohsuke Yatoh
e751e1036a Add InputConnection#performSpellCheck().
IME can use this method to redo spell checking after it has learned a
new user dictionary word.

Bug: 166304720
Test: atest CtsInputMethodTestCases:SpellCheckerTest
Change-Id: I956cd46f25bb77b7e1a6a3e1478c0d7efa1a056a
2020-12-15 22:48:47 +00:00
Soonil Nagarkar
ff097cef17 Move NUM_GPS_SIGNAL_QUALITY_LEVELS to GnssSignalQuality
This allows us to move GnssMetrics out of the client in a follow up CL.

Test: compiles
Change-Id: Idce044199f2ce223f893bfaecf43e5043a83bb94
2020-12-15 21:29:08 +00:00
TreeHugger Robot
0f04a2e670 Merge "Rename setTint to setColor" 2020-12-15 21:28:48 +00:00
Chris Tate
9bace5915a Merge "Make isAppBad() lock-free" 2020-12-15 20:31:55 +00:00
Alison Cichowlas
b09236d867 Fix sharing shortcuts not showing for Work Profile.
Bug: 175042485, 175240616
Test: per repro instructions in bug
Change-Id: Iecbc57369f46fcae72d6acdb997ea8daacc77979
(cherry picked from commit 17cb4137ad)
2020-12-15 20:09:33 +00:00
Alison Cichowlas
7cd8ae4855 Merge "Fix sharing shortcuts not showing for Work Profile." 2020-12-15 20:08:20 +00:00
Eugene Susla
224f3360ad Add owner to codegen annotations
Test: presubmit
Change-Id: Ie0de32e4f8321fe846e5f4aade7a087c1216a28c
2020-12-15 11:07:02 -08:00
Nicolas Geoffray
22e424f582 Merge "Make Class.getPackageName public." am: 3a76c4c9aa am: 7a0acb4d34 am: df634d7c4e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1519502

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I74d1fea098a9beeb3db99e35317bd7c1ae23ee83
2020-12-15 19:00:39 +00:00