Status Update
Comments
mo...@google.com <mo...@google.com> #2
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
va...@google.com <va...@google.com> #3
mo...@google.com <mo...@google.com> #4
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
ap...@google.com <ap...@google.com> #5
Branch: androidx-main
commit 9ad715087ea11e0d321c1da32cc2a62e8003a161
Author: George Mount <mount@google.com>
Date: Mon Mar 21 10:15:11 2022
Add window insets visibility
Bug: 217770337
Relnote: "WindowInsets companion now exposes the visibility
(whether they are on the screen, regardless of
whether thy intersect with the window), and the
size they could be if they are available on the device,
but not currently active."
Test: new tests for R+
Change-Id: I65182e3c8cdc868b9f6de3aef403c9f4d5074711
A compose/foundation/foundation-layout/src/androidAndroidTest/kotlin/androidx/compose/foundation/layout/WindowInsetsIgnoringVisibilityTest.kt
M compose/foundation/foundation-layout/api/public_plus_experimental_current.txt
M compose/foundation/foundation-layout/src/androidMain/kotlin/androidx/compose/foundation/layout/WindowInsets.android.kt
lu...@gmail.com <lu...@gmail.com> #6
Is there any temporary solution for a isVisible
function? Or should I wait for the issue to be fixed before I migrate Insets Accompanist to the Compose foundation insets?
va...@google.com <va...@google.com> #7
The isVisible
portion has been merged but didn't make it into 1.2.0-alpha07
that was just released.
If you'd like, you should be able to use isVisible
with one of the most recent androidx snapshots until it is released normally.
re...@gmail.com <re...@gmail.com> #8
In terms of temporary workaround, try this code:
val WindowInsets.Companion.isImeVisible: Boolean
@Composable
get() {
val density = LocalDensity.current
val ime = this.ime
return remember {
derivedStateOf {
ime.getBottom(density) > 0
}
}.value
}
Source:
ry...@educast.com <ry...@educast.com> #9
mo...@google.com <mo...@google.com> #10
LookaheadLayout
is now available, but isn't complete. SubcomposeLayout
implementations for BoxWithConstraints
and LazyColumn
/LazyRow
are yet to be done.
When those complete, I expect to make the look-ahead work with WindowInsets. You'll be able to see the target position of the IME, for example, and then customize your animation for it.
da...@gmail.com <da...@gmail.com> #11
Nice, thanks for the update. Where can we see the work in progress?
Please keep us updated!!
Nice work!
mo...@google.com <mo...@google.com> #12
Alex suggested a different solution that will work well. I can provide the source and target IME WindowInsets and you can use it to determine where the IME will be and the progress (combined with the current IME insets).
mo...@google.com <mo...@google.com>
ap...@google.com <ap...@google.com> #14
Branch: androidx-main
commit 977d53a595ad75ee1693140c84c052cc60bce305
Author: George Mount <mount@google.com>
Date: Fri Aug 26 14:58:13 2022
Added WindowInsets IME animation source and target
Fixes: 217770337
Relnote: "Added WindowInsets.imeAnimationSource and
WindowInsets.imeAnimationTarget to determine the
animation progress and know where the IME will be
after animation completes."
Test: new tests, manual
Change-Id: I356f1bac4ac4ff311573eb8df7227098b9186c20
M compose/foundation/foundation-layout/src/androidAndroidTest/kotlin/androidx/compose/foundation/layout/WindowInsetsActivity.kt
M compose/foundation/foundation-layout/src/androidAndroidTest/AndroidManifest.xml
A compose/foundation/foundation-layout/src/androidAndroidTest/kotlin/androidx/compose/foundation/layout/WindowInsetsAnimationTest.kt
M compose/foundation/foundation-layout/api/public_plus_experimental_current.txt
M compose/foundation/foundation-layout/src/androidMain/kotlin/androidx/compose/foundation/layout/WindowInsets.android.kt
na...@google.com <na...@google.com> #15
The following release(s) address this bug:
androidx.compose.foundation:foundation-layout:1.4.0-alpha01
Description
accompanist/insets provides a few additional pieces of information about each type of insets, other than just the current size.
These include:
isVisible
- if a type of insets are currently visible (especially useful for IME)animationInProgress
- whether that type of insets are currently being animatedanimationFraction
- the current fraction of animation (useful for running with another animation)layoutInsets
/animatedInsets
- contains the last normally applied insets, and the currently animated insets, respectively. (useful for informing external animations)