Converts a closure to a JavaFX EventHandler.
Converts a closure to a JavaFX EventHandler. It is used when the event properties will be used.
Enables following use:
button.onAction = (e:ActionEvent) => { println("Handling button action: " + e) doSomething(e) }
JavaFX Event subclass.
Closure that that takes scalafx.event.Event as argument.
JavaFX EventHandler which handle method will call handler
Converts a closure to a JavaFX EventHandler.
Converts a closure to a JavaFX EventHandler. It is used when information about event is not be used.
Enables following use:
button.onAction = () => { println("Handling button action") doSomething() }
JavaFX Event subclass.
Closure that will not handle event.
JavaFX EventHandler which handle method will call handler
Converts a
javafx.event.ActionEvent
instance to its ScalaFX counterpart.
Converts a
javafx.event.ActionEvent
instance to its ScalaFX counterpart.
JavaFX ActionEvent
ScalaFX ActionEvent
Converts a
javafx.event.Event
instance to its ScalaFX counterpart.
Converts a
javafx.event.Event
instance to its ScalaFX counterpart.
JavaFX Event
ScalaFX Event
Converts a
javafx.event.EventType
instance to its ScalaFX counterpart.
Converts a
javafx.event.EventType
instance to its ScalaFX counterpart.
Event Type
JavaFX EventType
ScalaFX EventType
Converts a
javafx.event.WeakEventHandler
instance to its ScalaFX counterpart.
Converts a
javafx.event.WeakEventHandler
instance to its ScalaFX counterpart.
Event Type
JavaFX WeakEventHandler
ScalaFX WeakEventHandler
8.0
(Since version ) see corresponding Javadoc for more information.
NOTE: use of handle
is deprecated in Scala 2.
NOTE: use of handle
is deprecated in Scala 2.12 and newer, you can use standard Scala syntax:
button.onAction = _ => { println("Handling button action") doSomething() }
For Scala 2.11 and older, you can use handle
to create a simple event handler when information about event is not be used.
Enables following use:
button.onAction = handle {
println("Handling button action")
doSomething()
}
JavaFX Event subclass.
code executed when event is handled.
JavaFX EventHandler which will wrap the input code handler
.
(Since version R19) Starting with Scala 2.12 handle{...}
can be replaced with idiomatic Scala code _ => {...}