Fixed
Status Update
Comments
tc...@google.com <tc...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit 9082f62682f853ad5251a1c79dde9eccba7abdd9
Author: Max Alfonso-Ying <maxying@google.com>
Date: Thu Apr 18 00:34:40 2024
[M2 text field] Apply background to decoration box
...instead of to the BasicTextField, so changing the
backgroundColor will properly change the decoration
box's background color.
Fixes: b/307694651
Test: added unit tests
Relnote: "Fix backgroundColor not applying to
TextFieldDecorationBox and OutlinedTextFieldDecorationBox.
Decoration boxes now accept a `shape` parameter."
Change-Id: I371c26718597cb36ac537e9412ce476532afb40d
M compose/material/material/api/current.txt
M compose/material/material/api/restricted_current.txt
M compose/material/material/integration-tests/material-demos/src/main/java/androidx/compose/material/demos/TextFieldDecorationBoxDemos.kt
M compose/material/material/src/androidInstrumentedTest/kotlin/androidx/compose/material/textfield/TextFieldDecorationBoxTest.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/OutlinedTextField.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextField.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextFieldDefaults.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextFieldImpl.kt
https://android-review.googlesource.com/3046833
Branch: androidx-main
commit 9082f62682f853ad5251a1c79dde9eccba7abdd9
Author: Max Alfonso-Ying <maxying@google.com>
Date: Thu Apr 18 00:34:40 2024
[M2 text field] Apply background to decoration box
...instead of to the BasicTextField, so changing the
backgroundColor will properly change the decoration
box's background color.
Fixes:
Test: added unit tests
Relnote: "Fix backgroundColor not applying to
TextFieldDecorationBox and OutlinedTextFieldDecorationBox.
Decoration boxes now accept a `shape` parameter."
Change-Id: I371c26718597cb36ac537e9412ce476532afb40d
M compose/material/material/api/current.txt
M compose/material/material/api/restricted_current.txt
M compose/material/material/integration-tests/material-demos/src/main/java/androidx/compose/material/demos/TextFieldDecorationBoxDemos.kt
M compose/material/material/src/androidInstrumentedTest/kotlin/androidx/compose/material/textfield/TextFieldDecorationBoxTest.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/OutlinedTextField.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextField.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextFieldDefaults.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/TextFieldImpl.kt
ap...@google.com <ap...@google.com> #3
Project: platform/frameworks/support
Branch: androidx-main
commit 3ac4b80f723df87ed65e475badcba309e2438562
Author: Jelle Fresen <jellefresen@google.com>
Date: Wed Jan 06 11:22:38 2021
Move frame clock test methods to test-utils
Remove the experimental advance methods for ManualFrameClock to internal
test utils, and clean up a few usages of clock control that were
incorrect.
Also yields after advancing now, which is desirable in all cases.
Fixes: 170708374
Test: ./gradlew compose:foundation:foundation:cC && \
./gradlew compose:material:material:cC && \
./gradlew compose:ui:ui-test:cC
Relnote: "Removed experimental monotonicFrameAnimationClockOf methods"
Change-Id: Ib753f5d3cb77dabc7727f677a73bb7da8dae5fe2
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollableTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyColumnTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/SwipeableTest.kt
A compose/test-utils/src/commonMain/kotlin/androidx/compose/testutils/AnimationClocks.kt
A compose/test-utils/src/commonMain/kotlin/androidx/compose/testutils/MockAnimationClock.kt
M compose/ui/ui-test/api/current.txt
M compose/ui/ui-test/api/public_plus_experimental_current.txt
M compose/ui/ui-test/api/restricted_current.txt
M compose/ui/ui-test/src/androidAndroidTest/kotlin/androidx/compose/ui/test/gesturescope/SendSwipeTest.kt
M compose/ui/ui-test/src/commonMain/kotlin/androidx/compose/ui/test/TestAnimationClock.kt
https://android-review.googlesource.com/1541367
Branch: androidx-main
commit 3ac4b80f723df87ed65e475badcba309e2438562
Author: Jelle Fresen <jellefresen@google.com>
Date: Wed Jan 06 11:22:38 2021
Move frame clock test methods to test-utils
Remove the experimental advance methods for ManualFrameClock to internal
test utils, and clean up a few usages of clock control that were
incorrect.
Also yields after advancing now, which is desirable in all cases.
Fixes: 170708374
Test: ./gradlew compose:foundation:foundation:cC && \
./gradlew compose:material:material:cC && \
./gradlew compose:ui:ui-test:cC
Relnote: "Removed experimental monotonicFrameAnimationClockOf methods"
Change-Id: Ib753f5d3cb77dabc7727f677a73bb7da8dae5fe2
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollableTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyColumnTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/SwipeableTest.kt
A compose/test-utils/src/commonMain/kotlin/androidx/compose/testutils/AnimationClocks.kt
A compose/test-utils/src/commonMain/kotlin/androidx/compose/testutils/MockAnimationClock.kt
M compose/ui/ui-test/api/current.txt
M compose/ui/ui-test/api/public_plus_experimental_current.txt
M compose/ui/ui-test/api/restricted_current.txt
M compose/ui/ui-test/src/androidAndroidTest/kotlin/androidx/compose/ui/test/gesturescope/SendSwipeTest.kt
M compose/ui/ui-test/src/commonMain/kotlin/androidx/compose/ui/test/TestAnimationClock.kt
Description
If
ManualFrameClock.advanceClock(nanos: Long)
is called from the main dispatcher, and its awaiters are also dispatched on the main dispatcher, two subsequent calls toadvanceClock
without a suspending call in between will result in the second frame time being missed by the awaiting coroutines.When awaiters get their frame time, their withFrameNanos lambda runs and they will be resumed, but the resume happens dispatched. If the caller is already occupying the main thread, the dispatch is enqueued and can only happen when the caller suspends.
If we yield right after sending the new frame time, the awaiters can be dispatched and potentially suspend on another call to withFrameNanos before the caller of advanceClock moves on.