Kotlin when multiple values ββdon't work when value is android view
I have implemented the function that is used in anko by recursively applying:
fun applyTemplateViewStyles(view: View) {
when(view) {
is EditText, TextView -> {
....
}
}
}
And I get the error "Function invocation" TextView (...) "expected"
So how can I write when with a sentence like 0, 1 why can't I do the same with Android View?
+3
source to share