Event for when a node gets shown on screen
anton nashatyrev
anton.nashatyrev at oracle.com
Tue Oct 1 05:53:04 PDT 2013
Hi Pedro,
you may try the following code:
Bindings.select(node.sceneProperty(), "window",
"showing").addListener(new ChangeListener<Boolean>() ....);
BTW, this way you could add the listener even when the node is not yet
attached to any scene or window.
Regards,
Anton.
On 29.09.2013 18:57, Pedro Duque Vieira wrote:
> Hi,
>
> More than once or twice I had the need to do something when a node first
> gets shown on screen. Like for instance do some animation or setup some
> parameters which are only valid when the node is showing.
>
> For this reason I think there is a need for an event that is triggered when
> the node becomes live, i.e. is shown on screen.
>
> Thanks, best regards,
>
More information about the openjfx-dev
mailing list