ron
12/26/2016, 6:53 PMoverride fun start(stage: Stage) {
super.start(stage)
stage.setOnCloseRequest {
it.consume()
controller.exit() }
}
ron
12/26/2016, 6:55 PMpermalmberg
12/26/2016, 6:56 PMpermalmberg
12/26/2016, 7:02 PM{
supposed to matter?
rectangle {
width = 100.0
height = 100.0
fill = Color.RED
}
compiles, but this does not:
rectangle
{
width = 100.0
height = 100.0
fill = Color.RED
}
ron
12/26/2016, 7:03 PMpermalmberg
12/26/2016, 7:04 PMedvin
12/26/2016, 7:16 PMrectangle
is a function that requires a code block parameter. If you call it without a parameter, it doesn't compile. Kotlin will not interpret a code block on the succeeding line as a parameter to a function on the previous line, hence the puke 🙂ron
12/26/2016, 7:16 PMpermalmberg
12/26/2016, 7:16 PMron
12/26/2016, 7:17 PMpermalmberg
12/26/2016, 7:17 PMpermalmberg
12/26/2016, 7:19 PMedvin
12/26/2016, 7:20 PMpermalmberg
12/26/2016, 7:21 PMedvin
12/26/2016, 7:21 PMpermalmberg
12/26/2016, 7:24 PMron
12/26/2016, 7:34 PMron
12/26/2016, 7:35 PMpermalmberg
12/26/2016, 7:37 PMron
12/26/2016, 7:38 PMedvin
12/26/2016, 7:38 PMedvin
12/26/2016, 7:39 PMcarlw
12/26/2016, 7:40 PMedvin
12/26/2016, 7:40 PMpermalmberg
12/26/2016, 7:41 PMedvin
12/26/2016, 7:42 PMcarlw
12/26/2016, 7:44 PMedvin
12/26/2016, 7:44 PMcarlw
12/26/2016, 7:45 PM