Fixed
Status Update
Comments
an...@google.com <an...@google.com> #2
We will solve it with adding an optional fraction param to methods in the scope: fillParentMaxWidth(fraction: Float)
If users need to get the size of the parent to do more complex calculations it will be currently recommended to use WithConstraints:
WithConstraints {
LazyColumnFor(myList) {
// in WithConstraints scope we have maxWidth/maxHeight in Dp
}
}
If users need to get the size of the parent to do more complex calculations it will be currently recommended to use WithConstraints:
WithConstraints {
LazyColumnFor(myList) {
// in WithConstraints scope we have maxWidth/maxHeight in Dp
}
}
ap...@google.com <ap...@google.com> #3
Project: platform/frameworks/support
Branch: androidx-master-dev
commit d3a3d65ae39bc35c1c99d1048ea5b6b94d2faa87
Author: Andrey Kulikov <andreykulikov@google.com>
Date: Tue Nov 03 15:52:31 2020
Add fractions in LazyItemScope modifiers
Relnote: Similarly to Modifier.fillMaxSize[Width|Height] we now support fractions in Modifier.fillParentMaxSize[Width|Height] inside the scope of LazyColumn/Row
Test: new tests for both row and column
Fixes: 166586426
Change-Id: I797e279db98215aa6f7c3e705f90442b5bf31f99
M compose/foundation/foundation/api/current.txt
M compose/foundation/foundation/api/public_plus_experimental_current.txt
M compose/foundation/foundation/api/restricted_current.txt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyColumnForTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyRowForTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/lazy/CachingItemContentFactory.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/lazy/LazyItemScope.kt
https://android-review.googlesource.com/1486062
Branch: androidx-master-dev
commit d3a3d65ae39bc35c1c99d1048ea5b6b94d2faa87
Author: Andrey Kulikov <andreykulikov@google.com>
Date: Tue Nov 03 15:52:31 2020
Add fractions in LazyItemScope modifiers
Relnote: Similarly to Modifier.fillMaxSize[Width|Height] we now support fractions in Modifier.fillParentMaxSize[Width|Height] inside the scope of LazyColumn/Row
Test: new tests for both row and column
Fixes: 166586426
Change-Id: I797e279db98215aa6f7c3e705f90442b5bf31f99
M compose/foundation/foundation/api/current.txt
M compose/foundation/foundation/api/public_plus_experimental_current.txt
M compose/foundation/foundation/api/restricted_current.txt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyColumnForTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/lazy/LazyRowForTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/lazy/CachingItemContentFactory.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/lazy/LazyItemScope.kt
Description