Status Update
Comments
sh...@google.com <sh...@google.com> #2
You may create a LazyPagingItems
through the extension
To construct a Flow<PagingData>
from static sample data for your preview, you can use
ja...@google.com <ja...@google.com> #3
The preview did compile, but no items displayed, other UI components such as Button works fine though.
The code now:
@Preview
@Composable
fun Preview() {
val usersFlow = flowOf(
PagingData.from(
listOf(
User("123", "33423", "2211", "Makanan", "Dapur", "Risal", "User", "Masakka")
)
)
)
DefaultTheme {
Surface() {
MainUi(
users = usersFlow.collectAsLazyPagingItems(),
onEditItem = {},
onDeleteItem = {}
) {
}
}
}
}
ra...@googlemail.com <ra...@googlemail.com> #4
I don't know if this is related but the IDE give me this message
High number of internal exceptions has been detected. This indicates a serious problem with the IDE. Please consider clean reinstall of Android Studio. If the problem persists, please report a bug by following the link below.
Build: AI-203.7717.56.2031.7583922, 202107261959,
AI-203.7717.56.2031.7583922, JRE 11.0.10+0-b96-7249189x64 JetBrains s.r.o., OS Linux(amd64) v5.11.0-7620-generic, screens 1920.0x1080.0, 1920.0x1080.0
AS: Arctic Fox | 2020.3.1; Kotlin plugin: 203-1.5.21-release-328-AS7717.8; Android Gradle Plugin: 7.0.0; Gradle: 7.0.2; Gradle JDK: version 11.0.10; NDK: from local.properties: (not specified), latest from SDK: (not found); LLDB: pinned revision 3.1 not found, latest from SDK: (package not found); CMake: from local.properties: (not specified), latest from SDK: (not found), from PATH: (not found)
ja...@google.com <ja...@google.com> #5
The reason is the regular preview is displaying the first frame, however with LazyPagingItems there is always one frame with empty data and only then we load the real values
sh...@google.com <sh...@google.com> #6
Nope, still the same.
ra...@googlemail.com <ra...@googlemail.com> #7
In my project preview also doesn't works. I tried all suggestion above.
Description
Auto library version: "androidx.car.app:app:1.0.0-beta01"
When setting TravelEstimate.setReimingSeconds(TravelEstimate.REMAINING_TIME_UNKNOWN) and then calling NavigationTemplate.setDestinationTravelEstimate(travelEstimate) an Exeption is thrown:
The documentation of TravelEstimate.setRemainingTimeSeconds contains this:
If i manually set it to REMAINING_TIME_UNKNOWN i get the exception in NavigationTemplate.Builder.setDestinationTravelEstimate()
Which says:
This is not consistent!
BR Samuel