but onDoubleClick is a different thing from onMous...
# tornadofx
w
but onDoubleClick is a different thing from onMouseClicked. there are a lot of side effects which shouldnt be so obstructive to find out.
r
That's the thing, it's not. "double click" is just a multiple clicks on the same spot, and JavaFX treats it accordingly. You could define a 100 click listener if your wanted.
w
yep. you see if you look at the source.
g
actually, to be consistent the method should probably be called setOnDoubleClick() which implies that it's a helper method (i.e. is similar to the setOnMouseClicked javafx method) which replaces the existing handler.
👍 1
all that said - it could be modified to add an additional handler in the extension function but it "could" be a breaking change if someone expects it to replace the existing handler (not likely)
You can just use event filters if you want to add multiple handlers (instead of using the helper method)
if you need an example let me know