Commit Graph

16917 Commits

Author SHA1 Message Date
Wu Ahan
d9dd71a4d7 Merge "Instrument jank of splash screen AVD and exit animation" into sc-v2-dev am: 43f59bb11b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16084829

Change-Id: If8539d0bbfe18404d5a3bd4013109bfc6ba23898
2021-11-03 02:57:02 +00:00
Wu Ahan
43f59bb11b Merge "Instrument jank of splash screen AVD and exit animation" into sc-v2-dev 2021-11-03 02:44:08 +00:00
TreeHugger Robot
d9358f6fec Merge "Remove deadlock path between InteractionJankMonitor and FrameTracker" into sc-v2-dev am: 9de009c3a5
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15828030

Change-Id: I516149ab133ca36bcc915bb9cbc65191342a8a01
2021-11-02 15:30:19 +00:00
Ahan Wu
aac160b107 Remove deadlock path between InteractionJankMonitor and FrameTracker
A deadlock path is found:
- FrameTracker$1.lambda$surfaceDestroyed (held A)
- InteractionJankMonitor.end (held B) -> FrameTracker.end (wait for A)
- FrameTracker.end -> InteractionJankMonitor.handleCujEvents (wait for B)
This cl resolves this by using a single lock among monitor and tracker.

Bug: 197804653
Test: atest InteractionJankMonitorTest --rerun-until-failure 100
Test: atest FrameTrackerTest --rerun-until-failure 100
Change-Id: Ia6aa196370bdb51b8a5c84c74a3d174a3d4b689f
2021-11-02 12:23:06 +00:00
Treehugger Robot
8ec2e93056 Merge "Create dedicated long variables." am: 78106c0ea4 am: dbca2d9a1f am: 742e35e203 am: 2afff12071
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1874248

Change-Id: I1a56e7e0c2052ccd6ab6fb9316aabfc4b97f4e2b
2021-10-29 16:04:25 +00:00
Treehugger Robot
2afff12071 Merge "Create dedicated long variables." am: 78106c0ea4 am: dbca2d9a1f am: 742e35e203
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1874248

Change-Id: I872014db65c9f1d1b1cfc0c9c6fb338fb0b3917f
2021-10-29 15:48:38 +00:00
Treehugger Robot
742e35e203 Merge "Create dedicated long variables." am: 78106c0ea4 am: dbca2d9a1f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1874248

Change-Id: I3c334fc91ff1e747a7eb6476cdc669b547ff23c1
2021-10-29 15:30:53 +00:00
kwekua
5aacac2a71 Create dedicated long variables.
Bug: 194532703
Bug: 204459169
Change-Id: Ic4c57d3797b19869e5c9151ccb183543ba5f6df0
2021-10-28 19:33:25 +00:00
Brad Stenning
ba7d862103 Merge "Allow a shared library to be positioned after the application on the classpath" am: 3120b13f56 am: 6e2646eacd am: dfb49ce58c am: 779d574b3d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1852914

Change-Id: I2e3425881355d2c5185038e2868b55b02867d973
2021-10-27 22:22:20 +00:00
Brad Stenning
779d574b3d Merge "Allow a shared library to be positioned after the application on the classpath" am: 3120b13f56 am: 6e2646eacd am: dfb49ce58c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1852914

Change-Id: Id6cf9e1e78db5f8aea040bcf51b24435a7529e0f
2021-10-27 22:02:48 +00:00
Brad Stenning
dfb49ce58c Merge "Allow a shared library to be positioned after the application on the classpath" am: 3120b13f56 am: 6e2646eacd
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1852914

Change-Id: I6b68af9a6f028103453e4cb6e014e852ef8838d1
2021-10-27 21:43:17 +00:00
Brad Stenning
89dfd0902e Allow a shared library to be positioned after the application on the classpath
This is useful if/when it's desired that an application contains the same
fully qualified class name that's also in the library.

The shared libraries that are treated in this manor are controlled by the resource
com.android.internal.R.config_shared_libraries_loaded_after_app

Bug: 179429740

Test: atest SharedLibraryLoadingTests

Change-Id: Ia37ff9bd545918d1e0f1f38548dcd86f177559d5
2021-10-27 10:06:16 -07:00
Treehugger Robot
92e4b728c7 Merge "Fix RRO loading from inside APEXes." am: de3baffb29 am: 23cd20c926 am: 09341a5ec4 am: c1ceac41b8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1830600

Change-Id: Ie51639568f0d24c90c1e10284de0536238ab1778
2021-10-26 23:36:17 +00:00
Treehugger Robot
c1ceac41b8 Merge "Fix RRO loading from inside APEXes." am: de3baffb29 am: 23cd20c926 am: 09341a5ec4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1830600

Change-Id: I47f88d5567eeccdf1d19d2d337d47d168ec98bf5
2021-10-26 23:16:06 +00:00
Treehugger Robot
09341a5ec4 Merge "Fix RRO loading from inside APEXes." am: de3baffb29 am: 23cd20c926
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1830600

Change-Id: I2d2fdda8b4f0fc6f4c9b32ca3e2e1c810b3d5384
2021-10-26 22:46:40 +00:00
Daniel Norman
653a1c1a28 Fix RRO loading from inside APEXes.
APEXes can already contain RRO APKs by using the 'rro' apex Soong
module field. However, these RROs were not being loaded properly by
Zygote or PackageManagerService.

For all RROs inside APEXes, the RRO uses the same overlay config that
is used for other RROs on the APEX's preinstalled partition.

For RROs targeting 'android', which are installed by Zygote
using AssetManager:
1. OverlayConfig looks for active APEXes in the apex-info-list file,
   which is already accessible to Zygote.
2. OverlayConfig passes the APEX module names to OverlayConfigParser,
   for each preinstalled-partition.
3. OverlayConfigParser uses OverlayScanner to scan the
   each /apex/<APEX>/overlay directory.

For other RROs:
1. PackageManagerService already parses and provides RROs inside APEXes
   to OverlayConfig.
2. RROs inside APEXes used to have no config rule applied because their
   path prefix (/apex/) did not match any partition rule. Now, their
   preinstalled path is used instead.

Bug: 199200417
Test: Define a static RRO targeting 'android' inside a /vendor APEX.
      Define a static RRO for settings provider inside a /vendor APEX.
      Observe APEXes are enabled by default.
Test: Make a change to an RRO inside a /vendor APEX.
      m <apex>; adb install <apex artifact>; adb reboot;
      Observe change has taken effect.
Change-Id: I2bce9bc704789329b8c6aac6d476f17ff6718e0f
Merged-In: I2bce9bc704789329b8c6aac6d476f17ff6718e0f
2021-10-25 13:04:24 -07:00
Rahul Sabnis
01eb71be00 Merge "Adding @SystemApi annotation to Bluetooth energy stats." am: a12c77ab44 am: a125c31d21 am: f91171d35e am: 6f74b5dd8b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1854179

Change-Id: I9e271a266c640fb739a5c394d0f5d091803143f4
2021-10-25 17:24:00 +00:00
Rahul Sabnis
6f74b5dd8b Merge "Adding @SystemApi annotation to Bluetooth energy stats." am: a12c77ab44 am: a125c31d21 am: f91171d35e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1854179

Change-Id: Ib49bb57260772b4200a11bb59e010ad8b8aa172e
2021-10-25 17:09:57 +00:00
Rahul Sabnis
f91171d35e Merge "Adding @SystemApi annotation to Bluetooth energy stats." am: a12c77ab44 am: a125c31d21
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1854179

Change-Id: Id4834acb7d38f9bd98e1eb29b9be0636a2f27a73
2021-10-25 16:53:04 +00:00
Shawn Lin
65c8136d34 Merge "Add APIs to get system bar heights" into sc-v2-dev am: 59f51a9538
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15611697

Change-Id: Ia9cb364e66ff9ef778e41d239a78da4b79e6d993
2021-10-25 04:23:07 +00:00
Shawn Lin
59f51a9538 Merge "Add APIs to get system bar heights" into sc-v2-dev 2021-10-25 04:07:12 +00:00
Wu Ahan
61cd0b63c4 Instrument jank of splash screen AVD and exit animation
Add jank instrument support for splash screen avd and exit animation.

Bug: 195736656
Test: see trace in comment
Change-Id: I1fdb9e14145bcf519eea99e440de74238e3c765c
2021-10-25 03:56:42 +00:00
Etienne Ruffieux
d372361fe3 Adding @SystemApi annotation to Bluetooth energy stats.
Added @SystemApi annotation to BluetoothActivityEnergyInfo
and UidTraffic getters for mainline compatibility. Replaced
raw array by List. Deleted unused constructors.

Tag: #feature
Bug: 200201373
Test: Manual
Change-Id: Id93215f48bf08d31ac269af9e064cf598f50b6d3
2021-10-21 20:39:31 +00:00
TreeHugger Robot
4183637e3e Merge "Hide SoftInput when INVALID_DISPLAY" into sc-v2-dev am: 0b4f292d62
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16057896

Change-Id: I8132a99155a003266d29e83acff45c5104b0bb3e
2021-10-21 10:09:02 +00:00
TreeHugger Robot
0b4f292d62 Merge "Hide SoftInput when INVALID_DISPLAY" into sc-v2-dev 2021-10-21 09:10:48 +00:00
TreeHugger Robot
09c1d2fad9 Merge changes I504d9c65,I45abcf87 into sc-v2-dev am: 8baec90550
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15962901

Change-Id: I403f2476824c51cbbbfe0bf5b8a5b5b7f6feb30f
2021-10-19 22:37:04 +00:00
TreeHugger Robot
8baec90550 Merge changes I504d9c65,I45abcf87 into sc-v2-dev
* changes:
  Utilize measured energy for multidisplay power attribution
  Update Screen and AmbientDisplay Power Calculators for multi-display
2021-10-19 22:20:47 +00:00
Issei Suzuki
02c4c404bc Merge "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade." into sc-v2-dev am: e7831937e7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16075530

Change-Id: I8a25f5fd2d2c3e9c0c47f0e6b6eac6c789dbed15
2021-10-19 10:37:24 +00:00
Issei Suzuki
e7831937e7 Merge "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade." into sc-v2-dev 2021-10-19 09:53:57 +00:00
Wilson Wu
b9e5fc383d Hide SoftInput when INVALID_DISPLAY
We only prevent to show soft input in
IMMS#startInputUncheckedLocked when
DISPLAY_IME_POLICY_HIDE is set.

If a display with DISPLAY_IME_POLICY_HIDE,
we should hide the soft input anyway.

Bug: 199991634
Test: atest CtsInputMethodTestCases
Test: Verify as following steps:
1) adb shell wm size 800x1280
2) adb shell wm density 213
3) atest MultiDisplaySystemDecorationTests#\
   testDisplayPolicyImeHideImeNoSystemDecorations

Merged-In: I3ab03667c28ec5beb6c3332aceaae4a63cd7309a
Change-Id: I3ab03667c28ec5beb6c3332aceaae4a63cd7309a
(cherry picked from commit d41ac0605c)
2021-10-19 08:05:42 +00:00
Shawn Lin
16496cb5c1 Add APIs to get system bar heights
In multi-display devices, there might be differnt cutout on each display
which also causes different status bar height.

Now we no longer overlay the status_bar_height dimen and keep it as
default value and add APIs to calculate the status bar size.

- Add APIs for getting status_bar_height & quick_qs_offset_height in
  system.
- Add APIs for getting split_shade_header_height and
  qs_header_system_icons_area_height in SystemUI.
- Remove all resource overlay for status_bar_height &
  quick_qs_offset_height.

Bug: 186604541
Test: atest SmallClockPositionTest DisplayLayoutTest
      HideDisplayCutoutOrganizerTest SizeCompatTests
      NotificationPanelViewControllerTest
Change-Id: I5a6dfcc6ff06da8ea0fe119fc9d4c089f13b0dff
2021-10-19 14:51:20 +08:00
TreeHugger Robot
0c43c6f304 Merge "Track latency of user switch journey" into sc-v2-dev am: e5d0befd2c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16049167

Change-Id: Ic59af9e1e2fbd2175ba00a3e470079adf5e83b9d
2021-10-18 21:53:59 +00:00
TreeHugger Robot
e5d0befd2c Merge "Track latency of user switch journey" into sc-v2-dev 2021-10-18 21:45:15 +00:00
Issei Suzuki
4731aa5e1c Keep FLAG_SHOW_WALLPAPER flag on NotificationShade.
Before this change, we controlled wallpaper visibility on the Lockscreen
by combination of visibility of NotificationShade window and
setting/resetting FLAG_SHOW_WALLPAPER flag on its window. When the flag
was removed while NotificationShade was still visible (e.g. OCCLUDE
transition starts on the Lockscreen), the wallpaper became immediately
invisible and caused a flicker.

With this change, we keep the FLAG_SHOW_WALLPAPER on NotificationShade,
and only rely on its visibility weather the wallpaper should be visible
or not on the Lockscreen.

Bug: 191438572
Test: existing tests + manual
  open GPay app from the lockscreen
  open emergency dialer and check the key pad reacts
Change-Id: I7876c92331125b00931218d9e5aca164a1ea50d9
Merged-In: I7876c92331125b00931218d9e5aca164a1ea50d9
2021-10-18 17:29:53 +02:00
Michael Wachenschwanz
05c4ff8a0c Merge "Update BatteryStatsImpl to handle multidisplay" into sc-v2-dev am: 684c0b4a77
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15913462

Change-Id: Id788a5ca13e871baa85bb2ada6ead28b50170e55
2021-10-15 21:52:10 +00:00
Michael Wachenschwanz
684c0b4a77 Merge "Update BatteryStatsImpl to handle multidisplay" into sc-v2-dev 2021-10-15 21:43:12 +00:00
TreeHugger Robot
ef7f80f1e5 Merge "Revert "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade."" into sc-v2-dev am: ae46cf3869
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16059309

Change-Id: Ia9e55ba7cacbda2267a996e977f73eb820c45f81
2021-10-15 13:33:01 +00:00
TreeHugger Robot
ae46cf3869 Merge "Revert "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade."" into sc-v2-dev 2021-10-15 13:15:24 +00:00
Daniel Chapin
33bc582317 Revert "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade."
This reverts commit 7f1a5a79d1.

Reason for revert: Droidfood blocking bugs bug: 203025772 & bug: 203041994

Bug: 203041994
Bug: 203030884
Bug: 203025772
Change-Id: Iecb089045525e24b5e5ece312016eb20400da575
Merged-In: I768c13d2959fb92d2a5d038df560e1575aea0712
2021-10-15 10:37:57 +00:00
Michael Wachenschwanz
3214255bab Utilize measured energy for multidisplay power attribution
Fixes: 194107383
Test: atest FrameworksCoreTests:BatteryStatsTests
Change-Id: I504d9c655382c2c6eb664e76ead88bce12da1ae4
2021-10-14 17:16:03 -07:00
Michael Wachenschwanz
e280aaca38 Update Screen and AmbientDisplay Power Calculators for multi-display
Bug: 200239964
Test: atest ScreenPowerCalculatorTest
Test: atest AmbientDisplayPowerCalculatorTest
Change-Id: I45abcf872de7239040f84b26bd9aa2af07cfaa7c
2021-10-14 17:16:03 -07:00
Michael Wachenschwanz
e031d50952 Update BatteryStatsImpl to handle multidisplay
Add screen on and doze timers for multiple displays.

For Battery history, charge/discharge logs and UnsupportedAppUsage, the
legacy screen state timers remain, as well. The legacy timers and
screen state tracking will now track overall screen state of the device.
The current overall screen state is the most "important" state currently
active.
Order of screen state importance is: on, doze, doze suspend, off.

Note: Utilizing per display measured energy will be handled in a follow
up CL.

Bug: 194107383
Test: atest FrameworksCoreTests:BatteryStatsTests
Change-Id: I4ad4f54b6897f406e4ec0f59834dd4762083e0d8
Merged-In: I4ad4f54b6897f406e4ec0f59834dd4762083e0d8
2021-10-14 17:15:57 -07:00
Lucas Dupin
54adb0f8a5 Track latency of user switch journey
Bug: 200160966
Test: atest UserSwitcherControllerTest
Test: atest KeyguardUpdateMonitorTest
Change-Id: Ic4fc85bd2e30029518cfe97d9839e08a687a1692
2021-10-14 11:02:09 -07:00
Issei Suzuki
8c828a63b6 Merge "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade." into sc-v2-dev am: 837add11c3
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15951265

Change-Id: Ie61022f24886603f9e2523fecab9811601cad402
2021-10-13 08:47:05 +00:00
Issei Suzuki
837add11c3 Merge "Keep FLAG_SHOW_WALLPAPER flag on NotificationShade." into sc-v2-dev 2021-10-13 08:31:35 +00:00
Issei Suzuki
54bfd5e650 Merge "Migrate WALLPAPER_LIGHT debug message to ProtoLog." into sc-v2-dev am: cd9c90750a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16004864

Change-Id: I4deaec1f298e177b90ce449ef10fd82b2c825a58
2021-10-12 15:25:14 +00:00
Issei Suzuki
cd9c90750a Merge "Migrate WALLPAPER_LIGHT debug message to ProtoLog." into sc-v2-dev 2021-10-12 15:09:42 +00:00
Issei Suzuki
7f1a5a79d1 Keep FLAG_SHOW_WALLPAPER flag on NotificationShade.
Before this change, we controlled wallpaper visibility on the Lockscreen
by combination of visibility of NotificationShade window and
setting/resetting FLAG_SHOW_WALLPAPER flag on its window. When the flag
was removed while NotificationShade was still visible (e.g. OCCLUDE
transition starts on the Lockscreen), the wallpaper became immediately
invisible and caused a flicker.

With this change, we keep the FLAG_SHOW_WALLPAPER on NotificationShade,
and only rely on its visibility weather the wallpaper should be visible
or not on the Lockscreen.

Bug: 191438572
Test: existing tests + manual (open GPay app from the lockscreen)
Change-Id: Id13ffbbd2c965e0dcc97effd3faf46fd7a8bb1a5
Merged-In: Id13ffbbd2c965e0dcc97effd3faf46fd7a8bb1a5
2021-10-12 09:51:26 +02:00
Issei Suzuki
bde317e6b1 Migrate WALLPAPER_LIGHT debug message to ProtoLog.
Test: manual
Bug: 191438572
Bug: 202392340
Change-Id: Ibf538fce834715dc32741f4b52808f99020f741e
2021-10-12 09:38:58 +02:00
TreeHugger Robot
d3b973ce7e Merge changes from topic "multiDisplayPowerProfile" into sc-v2-dev am: 71f8cf24e2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15856347

Change-Id: I41f6ea048c6e1cd7a525be9db8c00dadee0d4709
2021-10-08 06:21:16 +00:00