Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated for Jetpack Compose dev15 and Android Studio 4.2 Canary 5 #35

Merged
merged 1 commit into from Jul 27, 2020

Conversation

madhavajay
Copy link
Contributor

I got everything working, however I can't figure out the correct way to handle the three unchecked casts properly.
I left the @Suppress("UNCHECKED_CAST") commented near each one.

I guess this is something to do with Covariance / Contravariance etc, but I dont know enough about how to solve it. Seems theres a List and a Map with BackStack<*>. Would one solution be to have some kind of known Routing interface or class which is subclassed or implemented so that the type and its sub/super are known?

I would be interested in knowing how this should be fixed so that I can understand this whole <*> thing in Kotlin.

Copy link
Contributor

@ShikaSD ShikaSD left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, amazing job of converting these.
I have left a couple of comments, mostly referring to build files.

Regarding unchecked type checks, seems like for now we cannot avoid them all, as we are converting between more broad BackStack<Any> to very specific BackStack<T>. I think in these cases it is fine anyway, as we know that types are consistent based on the logic of the lib :)

settings.gradle Outdated Show resolved Hide resolved
router/build.gradle Outdated Show resolved Hide resolved
router/build.gradle Outdated Show resolved Hide resolved
router/build.gradle Outdated Show resolved Hide resolved
build.gradle Outdated Show resolved Hide resolved
app-lifelike/build.gradle Outdated Show resolved Hide resolved
build.gradle Outdated Show resolved Hide resolved
@madhavajay
Copy link
Contributor Author

Okay, I have made all the changes and squashed into a single commit. I will open a separate PR for the CI stuff after this is merged and I can rebase. Let me know if theres anything else you need me to change. 😊

@ShikaSD
Copy link
Contributor

ShikaSD commented Jul 25, 2020

@madhavajay amazing, thanks 👐 . I still see a new yaml file in the diff, can you recheck if you have removed everything?
Otherwise, LGTM.
cc: @zsoltk

- Updated to kotlin_version = "1.4-M3"
- Cleaned up dependencies and build.gradle files
- Removed redundant Column inside ScrollableColumn
- Optimised imports and updated androidx.ui.foundation.TextFieldValue
- foundation.TextFieldValue is now input.TextFieldValue
@madhavajay
Copy link
Contributor Author

@ShikaSD Sorry, I missed that when I squashed the commits. It's gone now, so I think we're ready for merge. Thanks for the patience.

@zsoltk
Copy link
Owner

zsoltk commented Jul 27, 2020

@madhavajay @ShikaSD thank you both!

@zsoltk zsoltk merged commit 16f32d5 into zsoltk:master Jul 27, 2020
@madhavajay madhavajay deleted the fix-dev15 branch July 27, 2020 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants