Commit Graph

18763 Commits

Author SHA1 Message Date
Robert Horvath
28951b551e Merge "[PATCH] Don't report after view detached from window." am: 88749cfd8f am: 698a7836d2
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2262742

Change-Id: Ia4a7fa688707877cf9145d3831d62587d44b9774
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-27 08:28:28 +00:00
Robert Horvath
698a7836d2 Merge "[PATCH] Don't report after view detached from window." am: 88749cfd8f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2262742

Change-Id: I63390f12c64d6c855b1c61f12d070bf258e3a735
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-27 07:57:17 +00:00
Robert Horvath
88749cfd8f Merge "[PATCH] Don't report after view detached from window." 2022-10-27 07:21:20 +00:00
Josep del Río
34b40ae557 Merge "Add global microphone mute key for keyboard" am: e85f271021 am: 13e8df2c0a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2263102

Change-Id: I31dc6e7e492de91da9def8b0ff33888edfbc0fd6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-21 21:19:45 +00:00
Josep del Río
13e8df2c0a Merge "Add global microphone mute key for keyboard" am: e85f271021
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2263102

Change-Id: Idf4643df3f011352ae07b1920ba2ded863ab7165
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-21 20:51:05 +00:00
LiZhihong
95c1165bb8 Add global microphone mute key for keyboard
This change will enable the "mic mute" key on keyboards to globally mute
the microphone using the SensorManager, which has UI implemented in
multiple places (quick shortcuts, privacy center, settings...).

Test: manual
Bug: 237355207
Signed-off-by: LiZhihong <lizh52@lenovo.corp-partner.google.com>
Signed-off-by: DingYong <dingyong2@lenovo.corp-partner.google.com>
Change-Id: I492e501503b0ab9f56e1fa84fcc77a8c798bcb83
2022-10-20 14:59:19 +00:00
derek.li
6e2a429d42 [PATCH] Don't report after view detached from window.
Check window view is not null in reportKeepClearAreasChanged

Bug: 254586205
Test: CtsAutoFillServiceTestCases
Change-Id: I0db582c6f73e2a0602bfb2968e2b10536b5242d5
2022-10-20 16:34:35 +08:00
Sunny Goyal
5f2e52127e Merge "Adding missing rotationChange in RemoteAnimationTarget" into tm-qpr-dev am: ff6a8b23df
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19947321

Change-Id: I0d54589ee834e0522531c3f75a178f72f3ab328e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 16:42:52 +00:00
Sunny Goyal
ff6a8b23df Merge "Adding missing rotationChange in RemoteAnimationTarget" into tm-qpr-dev 2022-10-18 16:32:28 +00:00
Tiger Huang
bcac7745ac Merge "Re-land "Enable LOCAL_LAYOUT"" into tm-qpr-dev am: b3c6384df9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20106621

Change-Id: I0f2ab2a923654383484442c70e651811fbc29631
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-14 13:52:29 +00:00
Tiger Huang
b3c6384df9 Merge "Re-land "Enable LOCAL_LAYOUT"" into tm-qpr-dev 2022-10-14 13:00:03 +00:00
Mark Punzalan
c1ec30e72c Merge "Remove active translation on Activity destroyed" into tm-qpr-dev am: 9c185693d4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20022962

Change-Id: I1d3c6b4776c2b635a2c40d26ec47daecd478fb72
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-13 18:04:58 +00:00
Mark Punzalan
9c185693d4 Merge "Remove active translation on Activity destroyed" into tm-qpr-dev 2022-10-13 18:00:08 +00:00
TreeHugger Robot
97fdee3996 Merge "Update layout direction if ViewRoot is preserved" into tm-qpr-dev am: 3c282790e4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20158130

Change-Id: I4c4f0a12f317219b86c57218eba9c87725ce91fb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-12 14:15:42 +00:00
TreeHugger Robot
3c282790e4 Merge "Update layout direction if ViewRoot is preserved" into tm-qpr-dev 2022-10-12 13:39:45 +00:00
Miranda Kephart
6b424e8870 Merge "Remove partial screenshot code" into tm-qpr-dev am: 5caa83b5c6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20067344

Change-Id: I5f2330cba6451f9c60e30d26049da24fdfa01362
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-11 14:19:07 +00:00
Miranda Kephart
5caa83b5c6 Merge "Remove partial screenshot code" into tm-qpr-dev 2022-10-11 13:42:48 +00:00
Riddle Hsu
39ef5efaa5 Update layout direction if ViewRoot is preserved
Otherwise if the language of the configuration is changed between
RTL and LTR, the layout direction may still keep the previous
direction after calling recreate().

Bug: 250868428
Test: The layout direction will change with below sample:
  Configuration config = getResources().getConfiguration();
  configconfiguration.setLocales(LocaleList.forLanguageTags("ar"));
  getResources().updateConfiguration(configuconfigration, null);
  recreate();
Change-Id: Iad405bf02b2f19cb3aa8cbc21f9bca67d8a53c30
2022-10-11 15:12:51 +08:00
Mark Punzalan
f15a444d18 Remove active translation on Activity destroyed
When a translated Activity is destroyed or translation is finished
(e.g., finishTranslation() call), we also have to remove the entry in
the active translations we are keeping track in
TranslationManagerService. Prior to this change, we were not removing
the entry in the Activity destroyed case, and this caused problems when
a new callback is registered (e.g., Gboard) because it would incorrectly
get an onStarted() call for the now-inactive translation.

This can happen relatively frequently when the device has a work
profile, since switching to apps across profiles re-creates the IME, and
in the case of Gboard, it registers a callback every time.

Also added additional logging on Activity destroyed and when callbacks
are registered and triggered.

Bug: 245911471
Test: atest UiTranslationManagerTest
Change-Id: If1881fd4588725021d38e5b9336c3e69bca17039
Merged-In: If1881fd4588725021d38e5b9336c3e69bca17039
2022-10-06 18:23:30 +00:00
TreeHugger Robot
2b2b0da539 Merge "Add InputDeviceBatteryListener to InputManager" into tm-qpr-dev am: 666111dfa7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19866529

Change-Id: Ice37f87eb776888b3cd9109d127976929ca6e45d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-05 21:14:19 +00:00
TreeHugger Robot
666111dfa7 Merge "Add InputDeviceBatteryListener to InputManager" into tm-qpr-dev 2022-10-05 20:52:59 +00:00
TreeHugger Robot
74443ebde1 Merge "Fix input when hardware renderer drawing is disabled." into tm-qpr-dev am: 0854d61745
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19993815

Change-Id: Ice90045eed7057cdef92ec2c1e28826222172a18
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-05 20:38:09 +00:00
TreeHugger Robot
0854d61745 Merge "Fix input when hardware renderer drawing is disabled." into tm-qpr-dev 2022-10-05 20:22:11 +00:00
Louis Chang
5b094c514a Merge "Updating the cached resource configuration if ViewRoot is perserved" into tm-qpr-dev am: 0c3a5f856b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19992762

Change-Id: I8068f3adcd98ffeb61d21d30904bccbf630f3df2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-05 14:33:53 +00:00
Louis Chang
0c3a5f856b Merge "Updating the cached resource configuration if ViewRoot is perserved" into tm-qpr-dev 2022-10-05 14:05:38 +00:00
TreeHugger Robot
7aed9ed928 Merge "Fix condition to dispatch config for visible window" into tm-qpr-dev am: 1cd69247c2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20108254

Change-Id: I60f9c81b6a5a6413766e15ea7e6c1df60948ea2c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-05 10:27:28 +00:00
Riddle Hsu
935b474bec Fix condition to dispatch config for visible window
The condition in [1] was accidentally inverted. Then the activity
might get an intermediate config from view root but ActivityRecord
isn't aware of that.

[1]: I19af6cf7f9a4a27fbc987d920630e2de95ced602

Bug: 245225302
Test: atest WindowManagerServiceTests#testRelayoutExitingWindow
Change-Id: I4cbbd52f32019fbc7347365156b1e95399d1ecc7
2022-10-05 10:07:25 +00:00
Tiger
ab6b5064b9 Re-land "Enable LOCAL_LAYOUT"
Test: regular rotation, fixed rotation, and seamless rotation
Test: PowerMenuMicrobenchmark#testPower_verifySystemPowerMenuAppears
Bug: 161810301
Bug: 175861564
Change-Id: Ic0315aaef76fc9e6899fac278002c75fc1a2909d
2022-10-05 17:26:59 +08:00
Daniel Norman
ce09a229dd Adds more OWNERS to a11y FW dirs. am: b6dc971384 am: 4292755d27 am: 2325eb5313 am: e9dd122ce4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2234907

Change-Id: I005464c49af46492ee791c3068ec1e21cdaea18f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-29 21:18:45 +00:00
Daniel Norman
b6dc971384 Adds more OWNERS to a11y FW dirs.
Bug: n/a
Test: n/a
Change-Id: I1331e89caf4942d2118e644ed3f9710daa66be95
2022-09-28 09:15:49 -07:00
Miranda Kephart
76140601a9 Remove partial screenshot code
It's broken currently, is extremely difficult to access, and will
need to be heavily rewritten/refactored anyway if we decide to
bring it back.

Fix: 249325548
Test: adb shell input keycombination -t 300 META_LEFT CTRL_LEFT
SHIFT_LEFT S
(now takes a regular screenshot)

Change-Id: I2cde564f6369b88bd4c6b20a9eecf8172fae7e7a
2022-09-27 15:13:28 -04:00
Maryam Dehaini
8679358882 Merge "Fixing input coordinates discrepancy" into tm-qpr-dev am: bf338c7633
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19947893

Change-Id: I471736a34549e0201bdeba90c7060894a964f338
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-26 20:32:35 +00:00
Maryam Dehaini
bf338c7633 Merge "Fixing input coordinates discrepancy" into tm-qpr-dev 2022-09-26 20:16:33 +00:00
TYM Tsai
dcc45bdd20 Merge "Fix view does not show fill dialog" into tm-qpr-dev am: 5bca0e0058
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19710492

Change-Id: I24d669ae62f5e5d9a3a1f1c30a6beff57d745460
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-23 00:03:58 +00:00
TYM Tsai
5bca0e0058 Merge "Fix view does not show fill dialog" into tm-qpr-dev 2022-09-22 23:42:38 +00:00
Jorim Jaggi
1f09cd1808 Merge "Revert "Re-land "Enable LOCAL_LAYOUT""" into tm-qpr-dev am: 52c3498acf
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20025004

Change-Id: I1256637878491e8f936ecc19b3617a3a0fbad972
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-22 22:35:38 +00:00
Jorim Jaggi
52c3498acf Merge "Revert "Re-land "Enable LOCAL_LAYOUT""" into tm-qpr-dev 2022-09-22 21:48:43 +00:00
Prabir Pradhan
b6f775cea2 Add InputDeviceBatteryListener to InputManager
System apps can now register an InputDeviceBatteryListener on a
per-device basis to be notified of battery changes.

- InputManager manages registration of the binder callback with
  InputManagerService to ensure that there is only one battery
  listener per process.
- The battery listener is invoked immediately upon registration
  to provide the initial battery state for the device.
- The callbacks are removed automatically when the process dies.
- This CL does not yet identify changes in battery state for monitored
  devices.

DD: go/inputdevice-battery-notifications

Bug: 243005009
Test: atest FrameworkServicesTests
Test: atest FrameworkCoreTests
Change-Id: Idf2b06a099155a6f5cc13b55dcd40852f54aa56c
Merged-In: Idf2b06a099155a6f5cc13b55dcd40852f54aa56c
(cherry picked from commit e86f73ac50)
2022-09-22 16:59:53 +00:00
Tiger Huang
b557bc88b8 Revert "Re-land "Enable LOCAL_LAYOUT""
This reverts commit 975dd2c513.

Reason for revert: This is too risky for tm-qpr1
Bug: 161810301
Bug: 175861564

Change-Id: If906b4d538885fca407ce0bd7039c9d35b507032
2022-09-22 13:24:37 +00:00
Tiger Huang
7f946269c8 Merge "Re-land "Enable LOCAL_LAYOUT"" into tm-qpr-dev am: b47c6f2061
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19963145

Change-Id: I2b1b8f36acbac91cdcdaec1f5f44b05a8226d9ea
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-21 22:16:16 +00:00
Louis Chang
615928575a Updating the cached resource configuration if ViewRoot is perserved
When configuration changed, an Activity was relaunched because the
new layout size is smaller than old layout size. However, the
mLastConfigurationFromResources was not updated when relaunching
Activity while the window is preserved.

If the same Activity was resized to the previous bounds and the
configuration changes are not cross the size buckets, the Activity
won't be relaunched. Meanwhile, the View#onConfigurationChanged
was not reported because `mLastConfigurationFromResources` was not
update-to-date and was the same with the new configuration.

Bug: 247013643
Test: resizing the app in split-screen
Change-Id: I392417e1e6cc8bb5e8be0006b3b81385c3ef41aa
2022-09-21 08:48:40 +00:00
Tiger Huang
b47c6f2061 Merge "Re-land "Enable LOCAL_LAYOUT"" into tm-qpr-dev 2022-09-21 06:10:48 +00:00
TYM Tsai
fc5f2a60d3 Fix view does not show fill dialog
Sometimes, views may not be visible for the user immediately after
laid out, so add flag for do the evaluation once the view is visible.

Bug: 234429643
Test: Manual, check the fill dialog is appeared
Change-Id: I6b96b68ffc4a4b1ee5f5056848c5c4996d21ae73
2022-09-19 22:51:25 +00:00
Brett Chabot
4f58dc16bf Fix input when hardware renderer drawing is disabled.
When drawing is disabled the window's layer won't have a valid buffer. This
causes surfaceflinger to set the window's touchableRegion to zero.
This commit sets a window crop when drawing is disabled, so surfaceflinger
set touchableregion from crop instead of buffer.
And it modifies LetterboxUiController to not reset the crop.

Test: cts and perf tests as documented in go/android-slimulator-dev-env
Bug: 229870984
(cherry picked from commit 32dfc98382)
Merged-In: I4d6ca513c3daf5818ded03eae00e551fc319ad69
Change-Id: Ic8e1b17af825951505d448509530edf3ea81af5b
2022-09-19 10:29:06 -07:00
Tiger Huang
d95c3121b6 Merge changes Ibc2f40dd,I37fb8ffc into tm-qpr-dev am: dea70726f6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19963144

Change-Id: I56d9cf4a11f38a8a574b7d5ab6c82ff770b7bdf1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-16 14:50:00 +00:00
Tiger Huang
dea70726f6 Merge changes Ibc2f40dd,I37fb8ffc into tm-qpr-dev
* changes:
  Don't perform config change if relayoutAsync
  Apply synced relayout if we have FLAG_WINDOW_VISIBILITY_CHANGED
2022-09-16 14:23:42 +00:00
Maryam
e286a1de93 Fixing input coordinates discrepancy
Their was a input coordinate discrepancy for dialogs when we use the wm
caption in the shell.
Test: tested manually on multiple builds
Bug: 244190356
Bug: 243950192

Change-Id: I84cf95a933e90062f20978e4e1f83276c100c326
2022-09-15 17:56:05 +00:00
Tiger Huang
975dd2c513 Re-land "Enable LOCAL_LAYOUT"
Test: regular rotation, fixed rotation, and seamless rotation
Test: PowerMenuMicrobenchmark#testPower_verifySystemPowerMenuAppears
Bug: 161810301
Bug: 175861564
Change-Id: I7d70445a90ba234e2ba6482552886c1808d0d233
2022-09-15 15:37:35 +08:00
Tiger Huang
f3b99eee95 Don't perform config change if relayoutAsync
mPendingMergedConfiguration wouldn't be updated if we didn't call
IWindowSession#relayout.

Bug: 244003094
Test: atest ToggleDarkThemeMicrobenchmark#testToggle
Change-Id: Ibc2f40dd986136d9b54f3a7f491f7517489e05af
2022-09-15 15:02:40 +08:00
Sunny Goyal
b8761ced34 Adding missing rotationChange in RemoteAnimationTarget
Bug: 221961069
Test: Presubmit
Change-Id: Ibea2ba0694c5afe77dc809e8ad890f620bb92fda
2022-09-13 22:03:18 -07:00