Since not all KEYCODE_MEDIA_* keycodes return true in isMediaKey(),
the naming can give confusion. This CL renames the method to
isMediaSessionKey() and revises its Javadoc.
Bug: 119789707
Test: make -j
Change-Id: I36786ccf5606977e6d971c13d77d950356561bda
It will allow to call this method in AndroidX Transition without reflection.
ChangeBounds#BOTTOM_RIGHT_ONLY_PROPERTY,POSITION_PROPERTY are restricted now as well as developers can just use setLeftTopRightBottom method instead (it was used as a performance optimization in third-party transitions backport)
Bug: 117521189
Bug: 117521197
Bug: 117521053
Test: new test added for the method
Change-Id: I0a29bc8cf0b3357e49f6be14270993a21a6dfeee
This CL starts a journey to discover a brave new inset world. The
path to get us there may be rocky, but it's going to be rocky.
One of the main pledges of the new API is that an app can retrieve
what is causing a certain inset easily. For that, we need to
dispatch metadata who is causing what inset, such that we can query
it from the client side.
Furthermore, the client will be able to manipulate insets directly,
but also listen to animation changes. We don't want to go through
window manager for that, thus, there needs to be a local codepath
from (global window state -> WindowInsets).
Because we have these two requirements, we dispatch the relevant
global window state for insets, represented by InsetsState, and
dispatch it to the client. On the client side we take the frame
and the InsetsState and generate WindowInsets out of it.
Bug: 118118435
Test: InsetsSourceTest, InsetsStateTest, InsetsSourceProviderTest,
InsetsStateControllerTest
Change-Id: I2bfe9dda376512916261823fc2ee35cbedeb6731
- Make a better distinction between surface bounds and buffer size by renaming setSize to
setBufferSize and removing setSize for all buffer-less surfaces.
- Adds an error check in SurfaceControl to ensure buffer size is only set for buffer-less surfaces.
- Updates color fade surface to use passed in transaction object.
Bug:114413815
Test: go/wm-smoke
Test: atest FrameworksServicesTests:DimmerTests
Test: atest FrameworksServicesTests:SurfaceAnimatorTest
Change-Id: I88bd1452d6b3b3009e73e26986027d6a5a9efebc
* changes:
ScreenMagnifier: Track SurfaceFlinger Input
Forward SurfaceInsets to InputWindowInfo
Track native changes: Rework InputApplicationInfo
Replace InputWindowInfo#inputChannel with an IBinder token.
Fix name for canReceiveTouchInput
Fix pointer capture
Cleanup Input left-overs.
Port other InputWindowHandles to input surfaces.
Port InputConsumerImpl to SurfaceFlinger input.
Pass InputWindowInfo to SurfaceFlinger.
This change is to support Auto case.
Auto may need to support displays without navigation bar by default,
because the display may be far away from driver.
Note: currently, hasNavigationBar is global since it's from config.
In future patches, it will also check hasSystemDecorations() on
secondary display.
TODO: We may find a way to make OEMs set hasNavigationBar() for each
display.
Fixes: 119584629
Test: atest WmTests
Test: atest InputMethodManagerServiceTests
Test: atest SystemUiTests
Change-Id: I427f8ad1f3da644a2bf79ee5b777830378515348
So that SurfaceFlinger can set the appropriate frame. See
frameworks/native commit and InputWindow.h for detailed
discussion.
Test: Manual
Bug: 80101428
Bug: 113136004
Bug: 111440400
Change-Id: I5df12fa3f90335f2045ee7107d3b1242ff0d00c5
First we move it inside of InputWindowInfo instead of InputWindowHandle
so it is part of the data sent across binder. Second we give it a persistent
identity of an IBinder token and use this for comparisons.
Bug: 80101428
Bug: 113136004
Bug: 111440400
Test: EndToEndNativeInputTest. Existing tests pass.
Change-Id: Id89a40e66887d834020f8e645fd1fb48adb7ee2e
The IBinder token is now being used as the UUID for InputWindows.
We can pass it around without the channel to avoid unnecessary FD
parcelling, duping, and other juggling.
Test: Existing tests pass.
Bug: 80101428
Bug: 113136004
Bug: 111440400
Change-Id: I8eba3fa05f249b7dfcb5c3d9817241cbfe9ab76c
IntelligenceManager must buffer ContentCapture events and send them to the
service in a batch, and this is the initial implementation of such batch:
it's just batching a pre-defined number of events, without any further
optimization (like flushing after x ms).
Test: manual verification
Bug: 111276913
Bug: 119220549
Change-Id: I96a4708fd3fcfd3098a0894a3ae3e967804cf4e6
We will classify the word as "dictionary" if we think user may want to look
it up. A "Dictionary" option will be shown in the floating toolbar
if users select words of this entity type.
A new Intent action is introduced to bring up the dictionary app.
The model that supports this entity type is not checked-in yet.
So no behavior change can be seen for now.
Test: Check-in the WIP model and try to select a "dictionary word".
Test: atest frameworks/base/core/tests/coretests/src/android/view/textclassifier/IntentFactoryTest.java
BUG: 68238822
Change-Id: Ib318d5b2abf79d61e55b33e397065a0714573121
Also don't show smart actions for selections in text with unsupported
characters.
Bug: 116321860
Test: atest android.view.textclassifier.TextClassifierTest \
android.text.util.cts.LinkifyTest \
android.text.util.LinkifyTest \
android.widget.TextViewActivityTest
Change-Id: Id271cab8aef6b9b13ef17f1a8654c7616f75cf13
1) For sysui or launcher used APIs to support multi-display:
- overridePendingAppTransitionMultiThumbFuture
- overridePendingAppTransitionRemote
2) Modify WindowAnimator pending layout change debug log for all displays.
Bug: 119530958
Test: atest ActivityManagerMultiDisplayTests
Test: atest SystemUITests
Change-Id: I46a118a21b4df42c0d1767b77d838956a53262d3
These methods are being reflected into and seem generally useful
to developers.
Bug: 117521349
Bug: 117521191
Test: new CTS in topic
Change-Id: I86e8a379e458aefe7fb2fe936b57eeeffa5ad42d
Augmented Autofill is a mechanism that will let a system-provided service
provide autofill suggestions when the stardand autofill can't.
Because the Augmented Autofill service is a system app, it has less restrictions
than the standard service; in particular, this service will be responsible for
drawing the autofill UI, although the framework will provide a mechanism to host
the window. Right now, it's creating a TYPE_APPLICATION_OVERLAY window in the
service process roughly below the focused view, but in the long-term it will
use the IME suggestion window to display it.
This CL provides the initial APIs and end-to-end workflow for the simplest
scenario, but it's still full of TODO's.
Test: atest CtsAutoFillServiceTestCases # to make sure it doesn't break it
Test: atest FrameworksCoreTests:SettingsBackupTest
Test: mmm -j150 packages/experimental/FillService &&\
adb install -r ${OUT}/data/app/FillService/FillService.apk &&\
adb shell settings put secure intel_service foo.bar.fill/.AiaiService &&\
adb shell settings put global autofill_smart_suggestion_emulation_flags 2 &&\
adb shell pm grant foo.bar.fill android.permission.SYSTEM_ALERT_WINDOW
Bug: 119638877
Change-Id: I8d59b4eab3e530cd89b81456681a72fdab532756
We were not calling it on all places it should. And even worse, it was called
when the view was not laid out yet, which caused a side-effect on TextViews
(as it was calling assumeLayout()).
Bug: 111276913
Fixes: 119786503
Test: manual verification on Hangouts
Test: atest android.view.cts.ViewTest \
android.widget.cts.TextViewTest \
android.widget.cts.EditTextTest \
CtsAutoFillServiceTestCases
Change-Id: I685460d9b1e0428ec0e5377826a549a678f6434e
1. Introduce Message.USER_LOCAL to allow caller to specify which
message is from the local user.
2. TextClassifierImpl will now encode the Person object to a user
id.
3. Fixed a bug in Person.equals check
BUG: 111437455
BUG: 111406942
Test: atest frameworks/base/core/tests/coretests/src/android/view/textclassifier/ActionsSuggestionsHelperTest.java
Change-Id: I6629f42244a402fa210f87afa88a629c2ca4a510
All these properties have getters and setters since API 11 and
should be accessed via those.
Bug: 117521221
Bug: 117520719
Bug: 117521672
Test: none
Change-Id: Id96421370abf6d9417d7411698aae7603c1e0ff1
This data is directly accessible via getMinimumWidth (API 16)
and setMinimumWidth (API 1). Also exposed in androidX via
ViewCompat
Identical for Height methods
Bug: 117521509
Bug: 117521475
Test: none
Change-Id: I2e92574acd053aecec9c992a89ee57fd9785415e
Let each display have one status bar and one navigation bar. This is
so on each display, status bar and navigation bar can be laid out with
apps and produce proper insets.
Bug: 117474929
Test: atest com.android.server.wm
Test: Watch YouTube video in fullscreen mode, and see if status bar
and navigation will be hidden as expected. Swipe on the edge
of screen and see if status bar and navigation bar are both
shown as expected.
Change-Id: I1550659b7cd1dd1676bf04483c5b68376ef42905
Action: ACTION_TRANSLATE
Text: EXTRA_TEXT
TODO: Consider introducing a "translate" schema to pass the text to
translate instead of using a string extra to define this.
Bug: 116020587
Test: manually tested by selecting foreign language text and watching
for a "Translate" action.
Change-Id: I046157f4b3e1aa60afaf3f123fdeecf406f712dc
It's not properly ignoring events when the service is not set, which is causing
issues on some apps.
Fixes: 119659731
Test: manual verification
Change-Id: Ie271b8fcfde0bc2a5d6bf7c73b88bd6c48d50fdb
NativeActivities do not receive onNativeWindowDestroyed callback when the activity is stopped. If
the app still uses the window object after the window is destroyed, the app can crash.
Test: run native-plasma from Android NDK. Launch activity & press home. Verify from the logs app
receives onNativeWindowDestroyed callback when its stopped.
Bug: b/111948775
Change-Id: I1de76feb7f4974b77b42b56e592ff6444713c699
That method was returning a boolean to indicate whether the IntelligenceManager
should be notify, so views with virtual hierarchy could return false.
But now it returns void and always notify, which makes the API easier to
understand and use.
Bug: 117944706
Test: m -j update-api doc-comment-check-docs
Test: atest CtsAutoFillServiceTestCases
Change-Id: I216cacb6edb144239b6eabe56ab177fc2582e1aa
This change puts the expand caret at the end of the notification header
if the new interruption model is turned on, and moves the bell icon on
noisy notifications from the end of the header to directly after the
header text.
Test: manually
Change-Id: I2a97f80920598f5f99f2d9c3b14d58858e1de1bb