Commit Graph

2004 Commits

Author SHA1 Message Date
Lauren Winston
eda30886f7 Merge "Add feature flag for Simple Cursor a11y feature." 2022-07-25 17:05:25 +00:00
Yi-an Chen
c48f21a557 Merge "Add PbA branding to clipboard" into tm-qpr-dev am: 2b04393a1d am: 89e8a943d8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19152769

Change-Id: I9c0a86d4eaab28baccceeef713cde9141d71d492
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-25 16:45:09 +00:00
Yi-an Chen
89e8a943d8 Merge "Add PbA branding to clipboard" into tm-qpr-dev am: 2b04393a1d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19152769

Change-Id: I5e965626328b0d60f67ff43094f38e28304287c0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-25 16:25:47 +00:00
Yi-an Chen
2b04393a1d Merge "Add PbA branding to clipboard" into tm-qpr-dev 2022-07-25 16:08:26 +00:00
Lauren Winston
3c7272f18e Add feature flag for Simple Cursor a11y feature.
Test: manual
Bug: 239976504

Change-Id: I6011f1817ff7d42a8f586acce40f009acdc53fc8
2022-07-23 03:28:08 +00:00
Neil Fuller
5ef61031b7 Add NtpTrustedTime.forceRefresh(Network)
Add NtpTrustedTime.forceRefresh(Network). If a component that uses
NtpTrustedTime is monitoring network connectivity, it should probably
provide the network to be used, otherwise there is a non-obvious
relationship between the network being monitored and the network
actually used.

Only one user of NtpTrustedTime is updated here as the other,
GnssLocationProvider / NtpTimeHelper, is going to be refactored in an
upcoming commit. Leaving it using the forceRefresh() method that doesn't
take a parameter is not a regression.

Bug: 222295093
Test: atest core/tests/coretests/src/android/util/NtpTrustedTimeTest
Test: Treehugger
Change-Id: I51db528d06359c33335c874aca524f5adee3f3a7
2022-07-22 10:34:42 +01:00
Binyi Wu
c236b0570d Merge "Create a feature flag for Clear Calling" into tm-qpr-dev am: 9c04c0ada9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18911004

Change-Id: I61616829d188fc0092c3e63c479c96c9fd86db51
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-22 00:49:40 +00:00
Orion Hodson
2b66f0f2db Merge "Document return values from android.util.Log logging functions" am: 07166bf3b1 am: c822b157e9 am: 198722c9ab am: 935cd289fe am: 35f78d9913
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2158819

Change-Id: I7fe496afce16d80a1ea5395907eb1ba472521856
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-22 00:06:25 +00:00
Orion Hodson
35f78d9913 Merge "Document return values from android.util.Log logging functions" am: 07166bf3b1 am: c822b157e9 am: 198722c9ab am: 935cd289fe
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2158819

Change-Id: Iba586ab55fc89ee28eaea318c2d152c82f63bba5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-21 23:49:07 +00:00
Orion Hodson
c822b157e9 Merge "Document return values from android.util.Log logging functions" am: 07166bf3b1
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2158819

Change-Id: Ia50d0d1945460168b0e8699e3142d17c573905bb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-21 22:33:42 +00:00
Orion Hodson
07166bf3b1 Merge "Document return values from android.util.Log logging functions" 2022-07-21 13:49:30 +00:00
Neil Fuller
66ba9ce8fa Merge "Add support for multiple NTP servers" 2022-07-20 10:18:13 +00:00
Orion Hodson
762723f190 Document return values from android.util.Log logging functions
Add a note about the return values from logging function since it was
asked in b/228523679.

Bug: 228523679
Fix: 228841312
Test: m
Change-Id: I39a3cad4ba10c4602e58ec9e88c7864ead4b9d85
2022-07-20 08:57:23 +01:00
Jeff Sharkey
d0c1067185 Merge changes from topic "jul15" am: 0e27faa039 am: 954431c4df am: fd0915aeec am: 70123a912d am: ad18b6f58c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2155659

Change-Id: Ie4563a12b72d038baeb952537c867b598db2c30e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-19 21:11:20 +00:00
Yi-an Chen
edfc44079c Add PbA branding to clipboard
Bug: 213357911

Test: Manually on Raven
Change-Id: If9944393fe64c7f94a5be139a538833d91ae98fe
2022-07-19 13:52:13 -07:00
Jeff Sharkey
ad18b6f58c Merge changes from topic "jul15" am: 0e27faa039 am: 954431c4df am: fd0915aeec am: 70123a912d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2155659

Change-Id: I6d5cc1577c71cf60fe16c62d5523cfb5c3a10468
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-19 20:20:04 +00:00
Jeff Sharkey
954431c4df Merge changes from topic "jul15" am: 0e27faa039
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2155659

Change-Id: Ie949e0bb40967581190f7b98bb5005bab19cb7fb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-19 19:12:28 +00:00
Jeff Sharkey
c6b3699b63 Offer explicit 3-byte vs 4-byte modified UTF-8.
As documented in art/runtime/jni/jni_internal.cc, ART has deviated
from the RI by using a 4-byte encoding instead of the 3-byte encoding
required by the JNI specification.

Some users are okay with this 4-byte encoding (where they control
both the reading and writing logic) but other users require
compatibility with the DataOutput/DataInput API contract, so this
change lets users request either behavior.

This change now exercises all tests in both 4-byte and 3-byte modes,
and exhaustively confirms that all valid code-points match the
DataOutput/DataInput contract when in 3-byte mode.

Benchmark results still show significant performance benefits when
using this 3-byte encoding over the upstream RI:

    timeRead_Upstream_mean (ns):                  5090068
    timeRead_LocalUsing3ByteSequences_mean (ns):  1996032
    timeRead_LocalUsing4ByteSequences_mean (ns):  1813250

    timeWrite_Upstream_mean (ns):                 3856276
    timeWrite_LocalUsing3ByteSequences_mean (ns): 1632697
    timeWrite_LocalUsing4ByteSequences_mean (ns):  886503

Bug: 236923096
Test: atest FrameworksCoreTests:CharsetUtilsTest
Test: atest FrameworksCoreTests:FastDataTest
Test: atest FrameworksCoreTests:XmlTest
Test: atest FrameworksCoreTests:BinaryXmlTest
Test: ./frameworks/base/libs/hwui/tests/scripts/prep_generic.sh little && atest CorePerfTests:FastDataPerfTest
Change-Id: Ibddd36410a0d4a909522de011f23a337b53d6889
2022-07-19 10:36:37 -06:00
Your Name
16da9e4652 Create a feature flag for Clear Calling
Test: manual

Bug: 236074207
Change-Id: I53f682fa63a6614037e966b5d8cc724d420dc065
Merged-In: I53f682fa63a6614037e966b5d8cc724d420dc065
2022-07-19 13:13:56 +00:00
Neil Fuller
0f2b48d1d6 Add support for multiple NTP servers
Add support for multiple NTP servers in NtpTrustedTime. The algorithm to
select the server is documented in comments in that class. Tests have
been updated accordingly.

This commit changes config.xml, removing (string) config_ntpServer and
replacing it with (string-array) config_ntpServers. It also modifies
command line and settings behavior.

Bug: 223365217
Test: atest frameworks/base/core/tests/coretests/src/android/util/NtpTrustedTimeTest.java
Test: atest frameworks/base/services/tests/servicestests/src/com/android/server/timedetector/
Test: atest cts/tests/tests/os/src/android/os/cts/SystemClockSntpTest.java
Test: adb shell settings put global ntp_server "ntp://time.google.com\|ntp://time.android.com"
Test: Inspection: adb shell dumpsys network_time_update_service
Test: Inspection: adb shell dumpsys time_detector
Change-Id: I5e19a4d82c9771448940b9f1db1689f21508667b
2022-07-18 14:50:02 +01:00
Neil Fuller
d3d6a4d154 Further refactoring for multiple NTP servers
Further refactoring to support adding multiple NTP servers in a later
commit. The logic for multiple servers will be added to forceRefresh()
later.

This commit also contains some refactoring to support improved testing
of NtpTrustedTime.forceRefresh(). Tests for the existing behavior have
been added here.

As part of this change, SntpClient / NtpTrustedTime /
NetworkTimeUpdateService have also been extended to pipe information
about the IP address of the NTP server used to obtain the time back to
the NetworkTimeUpdateService for improved logging / debugging support.

Bug: 223365217
Test: atest frameworks/base/core/tests/coretests/src/android/util/NtpTrustedTimeTest.java
Test: atest frameworks/base/services/tests/servicestests/src/com/android/server/timedetector/
Test: atest cts/tests/tests/os/src/android/os/cts/SystemClockSntpTest.java
Test: Inspection: adb shell dumpsys network_time_update_service
Test: Inspection: adb shell dumpsys time_detector
Change-Id: Ia0f13e2c8cbd102d677797b745414d8ab5fa1eba
2022-07-14 09:43:03 +01:00
Neil Fuller
08dac6774b Refactoring before supporting multiple NTP servers
Refactoring changes to make it easier to support NTP configuration that
contains multiple NTP servers to try. As part of this change, the NTP
server configuration is being changed from a simple hostname to a URI in
the form ntp://<host>[:port]. This is a local scheme introduced for this
commit for this purpose and not (currently) an official, registered IANA
URI scheme.

Settings parsing in NtpTrustedTime retains support for the simple
hostname-only form to avoid introducing incompatibilities when devices
upgrade and have settings values from earlier releases.  All other cases
(config.xml, commandline) are updated here to only support the new URI
form as these don't have backwards compatibility guarantees.

A later commit will add:
+ The settings / config changes to support a list of URIs in the format
  introduced in this commit, i.e. in place of the single one supported
  today.
+ The server request loop / server stickiness need to support multiple
  servers.

Switching to a URI over a simpler encoding scheme means:
1) Not having to deal with parsing awkward host + port cases, like IPv6
   addresses which contain colons, e.g. "[:::1]:1234" (these are used in
   in our tests).
2) Opens up the possibility of future protocols like NTS via a different
   URI scheme, and future parameterization of NTP server config with
   query params, paths, or similar.
3) Easy delimiting of lists later using a whitespace character like
   space, which will be encoded when part of a URI. This can be used for
   extending settings parsing to support multiple, space-delimited
   configs as settings code doesn't support multi-value settings out of
   the box (unlike config / commandline cases, which are comparatively
   easy).

This commit contains a new OWNERS file for NtpTrustedTimeTest. The file
has been populated with ownership information for TypedValueTest using
information from the OWNERS for the code under test.

Ignore-AOSP-First: The OWNERS change relates to a file landing
  internally
Bug: 223365217
Test: atest frameworks/base/core/tests/coretests/src/android/util/NtpTrustedTimeTest.java
Test: atest cts/tests/tests/os/src/android/os/cts/SystemClockSntpTest.java
Change-Id: I3afbd04659b4e4ee336619ea5ac6db7588057d6e
2022-07-12 15:30:09 +01:00
Neil Fuller
28f3fe363b Switch NetworkTimeUpdateService to internal API
Switch NetworkTimeUpdateService to using TimeDetectorInternal instead of
the binder API.

The NetworkTimeUpdateService runs in the system server, so it does not
have to use binder to communicate with the time_detector.

Also update NetworkTimeSuggestion to include uncertainty so that it
contains all the information needed for future usecases associated with
GnssLocationProvider.

Bug: 219693030
Bug: 222295093
Test: atest services/tests/servicestests/src/com/android/server/timedetector/
Test: atest services/tests/servicestests/src/com/android/server/timezonedetector/
Test: atest core/tests/coretests/src/android/app/timedetector/
Change-Id: I4665da76429bc333b34769fc362221581472690e
2022-07-08 13:40:33 +01:00
Neil Fuller
83ad73ecdc Move network time logic out of AlarmManagerService
Move network time logic out of AlarmManagerService in preparation for
a future refactoring. The TimeDetectorService is now a better home for
functionality associated with time signals, as it should receive most
time signals from various sources so it can determine whether the
device's system clock needs to change.

Although the TimeDetectorService is not currently informed every time
the NtpTrustedTime obtains a new time, it should be in future after
further work in later commits.

This change modifies the logic in SystemClock to match the GNSS time
logic in the same class, i.e. rather than calculating the "current time"
in the system server and then sending it over binder (introducing a
delay), the latest information needed to compute the time is sent to the
client, which then calculates the current time.

Bug: 219693030
Bug: 222295093
Test: atest services/tests/servicestests/src/com/android/server/timedetector/TimeDetectorServiceTest.java
Test: atest cts/tests/tests/os/src/android/os/cts/SystemClockSntpTest.java
Test: Treehugger
Change-Id: I80ea52877352122b52ac54daed8b092f3cc18e02
2022-07-07 13:11:21 +01:00
Sarup Dalwani
c56894bd8e Merge "Adding Flag to allow/restrict intent redirection." 2022-06-24 05:26:34 +00:00
Binyi Wu
f5c5477629 Create a feature flag for Clear Calling
Test: manual

Bug: 236074207
Change-Id: I53f682fa63a6614037e966b5d8cc724d420dc065
2022-06-17 13:59:01 +08:00
Sarup Dalwani
03d7c99780 Adding Flag to allow/restrict intent redirection.
This flag will allow/restrict intent redirection to/from clone profile.
This is to ensure that framework is not impacted by intent redirection
till we are ready to launch.
The default is false, once ready to launch we would set it true and
eventually remove it.
The flag can be modified through Settings>System>Developer
options>Feature
flags>settings_allow_intent_redirection_for_clone_profile.

Bug: 236221777
Test: tested this by flashing the device along with intent redirection
code.
Design Document: go/intent-redirection-blue-doc

Change-Id: I98d57ef6ff3883b423ada7b3d567425720dc5665
2022-06-16 11:05:36 +00:00
Shawn Lin
1bda88119c Merge "Replace DisplayManager.getStableDisplaySize with max Display.Mode" into tm-dev am: 15cb562bcd am: 02c07a76ba am: 7c604236cc am: 95b2a95bea
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18485561

Change-Id: I3d42949c53f1512ac2adc07347369383bcfc2f05
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-24 05:21:28 +00:00
Shawn Lin
7c604236cc Merge "Replace DisplayManager.getStableDisplaySize with max Display.Mode" into tm-dev am: 15cb562bcd am: 02c07a76ba
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18485561

Change-Id: Ifab44e33ac17ab673954019236b74f1fe4bfa4e4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-24 04:11:22 +00:00
Shawn Lin
0f7cc0128b Replace DisplayManager.getStableDisplaySize with max Display.Mode
The DisplayManager.getStableDisplaySize is not the right way to get the
size we want for screen decorations and display team is going to get rid
of it.

Instead, we use the maximum display size supported by the display as the
base size to define the cutout and rounded corner configs.

Also fixed a bug that DisplayCutoutBaseView didn't update the
shoudDrawCutout config when display change.

Bug: 230227839
Test: 1. On foldable device, fold and unfold the device and check if the
         cutout is correctly drawn.
      2. On device supporting multiple resolutions, switch resolution
         between FHD & QHD and check if the cutout is correctly drawn.
Test: atest LocalDisplayAdapterTest DisplayCutoutTest
           ScreenDecorationsTest RoundedCornersTest
           DisplayCutoutBaseViewTest
Change-Id: I7a602b5abd7d6a21d17eae4f8e99414eaf765fa5
2022-05-21 14:56:30 +00:00
TreeHugger Robot
ad66340361 Merge "[SparseSetArray] optimize copy constructor" into tm-dev am: 79286a97fd am: 8a160c4937 am: bfe637c5fe am: 3c962891d6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18415062

Change-Id: Id32e0cdbcc6c4117ce33461e4e9977578c9bc543
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-18 23:52:22 +00:00
TreeHugger Robot
f106d488b3 Merge "[SparseSetArray] optimize copy constructor" into tm-dev am: 79286a97fd am: d014ec92b5
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18415062

Change-Id: I4980b014251db3e48abcaab916a9adf8fd60e0da
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-18 22:15:05 +00:00
TreeHugger Robot
3c962891d6 Merge "[SparseSetArray] optimize copy constructor" into tm-dev am: 79286a97fd am: 8a160c4937 am: bfe637c5fe
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18415062

Change-Id: Id9608490dfa4aed3055df6f6f5c42a071074bf2a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-18 22:13:45 +00:00
Songchun Fan
c0ac1d37d5 [SparseSetArray] optimize copy constructor
BUG: 232347307
Test: atest android.util.SparseSetArrayTest
Change-Id: Ie046f557098ddc168b86523700cc06feede97e5e
2022-05-16 19:26:05 +00:00
TreeHugger Robot
f22ab3d69b Merge "[Panlingual] Add a flag to control opt-in/out" into tm-dev am: aaf912305b am: 4219739b2b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18161842

Change-Id: If9a7264ad2373f9acb9e67cb7ef2ed20e516620b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-06 15:40:30 +00:00
TreeHugger Robot
641c1724ae Merge "[Panlingual] Add a flag to control opt-in/out" into tm-dev am: aaf912305b am: 8a6837a777 am: f99124c9e5
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18161842

Change-Id: I1cfb515047ca776ef0059d3a936a568744bd751d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-06 15:38:33 +00:00
TreeHugger Robot
150ae67c72 Merge "[Panlingual] Add a flag to control opt-in/out" into tm-dev am: aaf912305b am: dfa287cf60
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18161842

Change-Id: Ib5e6bfeac338d64f7292d70c01b05e56f5de188d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-06 13:37:21 +00:00
tom hsu
94af43295c [Panlingual] Add a flag to control opt-in/out
Bug: 231396734
Test: local
Change-Id: Ia07ff3ce3202b5017533cca39418085c1e43882e
2022-05-04 15:00:06 +08:00
TreeHugger Robot
803cd793af Merge "Reuse a same buffer per session instead of reallocating each time." into tm-dev am: ccf6f21ad8 am: d5009ae598
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17946676

Change-Id: Ifb9098c2a1c45772ba2358d9fd53ffff5a619d6b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-02 22:51:05 +00:00
TreeHugger Robot
a39ab093fa Merge "Reuse a same buffer per session instead of reallocating each time." into tm-dev am: ccf6f21ad8 am: d5009ae598 am: 90e0ae2e51 am: f070747cd7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17946676

Change-Id: If6e37c2f3961abf90dc9a7077dce2f075067a6ae
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-02 12:16:08 +00:00
TreeHugger Robot
f070747cd7 Merge "Reuse a same buffer per session instead of reallocating each time." into tm-dev am: ccf6f21ad8 am: d5009ae598 am: 90e0ae2e51
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17946676

Change-Id: I71e960b904c27864d16a34745d235f15c7c347dd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-30 03:47:27 +00:00
Billy Lau
53abe6077d Reuse a same buffer per session instead of reallocating each time.
Previously, a fixed size buffer was allocated each time a call to
`computeSha256DigestForLargeFile` was made. This causes
undesirable performance issues. This change allocates a buffer
per apex/module-update session instead.

To fix this, that method is amended to take in a buffer passed
in by the caller instead.

To aid in the usage of this API, a new method called
`createLargeFileBuffer` is introduced to help callers allocate
a pre-determined buffer size to be passed into the SHA
computation method based on whether the device is low RAM
device or not.

Subsequent RSS benchmarking shows that this helps to
significantly lower the RSS high watermark (HWM) for
the `system_server` process into just noise.

Bug: 229137737
Test: Manual
Change-Id: I6d2d17353f999bd6cfb937cd5ae6e6925f1353ac
2022-04-29 15:27:50 -05:00
Ilya Matyukhin
c5cf864de3 Merge "Enable RRS (FHD<->QHD) support for UDFPS" into tm-dev am: 559244bd5e am: fa923feadb
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17844871

Change-Id: Ie175e9d5065f6489a854cf94a4c4f556b777cb24
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-21 06:34:36 +00:00
Ilya Matyukhin
6c7cd10ce3 Merge "Enable RRS (FHD<->QHD) support for UDFPS" into tm-dev am: 559244bd5e am: 0ea20eac6f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17844871

Change-Id: I21fcfbd34acf15528d5c0fc855b64923aba99da1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-21 06:25:23 +00:00
Ilya Matyukhin
84438ca22b Enable RRS (FHD<->QHD) support for UDFPS
UDFPS position and assets are configured in pixels in native
resolution. This CL adds a mechanism to detect a runtime resolution
change and scale the UDFPS coordinates accordingly.

Bug: 223342274
Test: atest SystemUITests:com.android.systemui.biometrics
Change-Id: Iaa1f3d633b50019d06bdecb5063490ad6eb11272
2022-04-20 21:15:14 +00:00
Shawn Lin
5981e3255a Merge "Support scaled cutout & roundedcorners when resolution is overridden" into tm-dev am: 88ed5ca17a am: 6de716209c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17232290

Change-Id: Ia48552185059896889298a96f14963660a755771
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-20 18:38:13 +00:00
Shawn Lin
4d66e54421 Merge "Support scaled cutout & roundedcorners when resolution is overridden" into tm-dev am: 88ed5ca17a am: feac07a0e9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17232290

Change-Id: I58559a9487443d2bbabd976a56e37077b063f0e3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-20 18:23:33 +00:00
shawnlin
bcea9fd89e Support scaled cutout & roundedcorners when resolution is overridden
In current desgin, the confgis for cutout and rounded corner are based
on the original display size. If the display resolution is overridden,
cutous and rounded corners will be drawn in incorrect places with
incorrect size.

We should load the cutout & rounded corners with the orignal display
size and then scale the results with the display ratio which is
calculated by dividing current size with original size.

Bug: 209592558
Test: manual:
      1. Go Settings-> Display-> Screen Resolution
      2. Switch between FHD+ and QHD+
      3. Check if the cutout and rounded corner looks the same as they
	 are in the original display size.
Test: manual:
      1. adb shell wm size 1080x2340
      2. Check if the cutout and rounded corner looks the same as they
         are in the original display size.
Test: atest DisplayCutoutTest LocalDisplayAdapterTest
          ScreenDecorationsTest RoundedCornerResDelegateTest
Change-Id: Iea42b73c0276b82983c1ddbce9455355afdc164d
2022-04-20 10:03:19 +08:00
Kedar Chitnis
c60e7c4119 Guest mode updates to resolve privacy concerns in guest mode
- Add API in IUserManager to allow setting ephemeral user flag
- Implement and export this API in UserManagerService and UserManager
- Set guest as ephermal by default when createGuest in UserManager is called
- Handle guest user switching in UserSwitcherController for the case
  of dynamic change of ephemeral state
- Add persistant notification when in guest mode to indicate
  - if guest session is new or previously used.
  - if guest session will be cleared on exit or not
- Add buttons in persistant notification to reset or exit guest
- Add flags to enable/disable this feature

Bug: 214031645
Screenshots: go/ephemeral-guest-b-214031645-ux
Test: Manual test using sunfish, atest SystemUITests, atest SettingsRoboTests

Relands ag/16545010 after resolving post submit issues

Revert "Revert "Guest mode updates to resolve privacy concerns in guest mode""
This reverts commit dd5c440802.

Change-Id: I46b8ab527bab8fe665114ed0fffbb06a59d49a77
Merged-In: I46b8ab527bab8fe665114ed0fffbb06a59d49a77
2022-04-14 09:47:35 +00:00
TreeHugger Robot
0a7b6dea61 Merge changes from topic "presubmit-am-77b3b2d8d8b04e6abd7f7148c74f7ca8" into tm-mainline-prod am: 5ae2cad602
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17571717

Change-Id: If2a8a9ff2fcd376f4944612da6b802fa0c75c2f3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-08 00:31:15 +00:00