Aw: Re: New properties: focusOwner and focusOwnerWithin

2024-01-11 Thread Marius Hanl
ually, already using it for our tables.   -- Marius   Gesendet: Donnerstag, 12. Oktober 2023 um 00:15 Uhr Von: "John Hendrikx" An: openjfx-dev@openjdk.org Betreff: Re: New properties: focusOwner and focusOwnerWithin I don't see how a method like `setFocused` could possibly work w

Re: New properties: focusOwner and focusOwnerWithin

2023-10-11 Thread John Hendrikx
I don't see how a method like `setFocused` could possibly work without violating its specification.  When a Scene is present, it could in theory update the focusOwner, but when no Scene is present it probably needs to remain `false` even when set to `true` (as otherwise you could set multiple n

Re: New properties: focusOwner and focusOwnerWithin

2023-10-11 Thread Michael Strauß
I think the cleanest solution would be to have the implementation of Node.focused match its specification: Indicates whether this {@code Node} currently has the input focus. To have the input focus, a node must be the {@code Scene}'s focus owner, and the scene must be in a {@code Stage

Re: New properties: focusOwner and focusOwnerWithin

2023-10-09 Thread Martin Fox
> On Oct 7, 2023, at 2:00 PM, Michael Strauß wrote: > > JavaFX has two closely related focus concepts: `Node.focused`, which > can apply to any number of nodes in a scene graph, and > `Scene.focusOwner`, which is the single node in a scene graph that > accepts user input. The current JavaDoc f

Re: New properties: focusOwner and focusOwnerWithin

2023-10-08 Thread John Hendrikx
I would be interested to know what use cases for these are, and what would be then left of the use cases for the existing focusWithin and focusVisible properties?  The ticket referred doesn't give one and only reports a bug. Before implementing a second set of these types of properties, I woul

New properties: focusOwner and focusOwnerWithin

2023-10-07 Thread Michael Strauß
JavaFX has two closely related focus concepts: `Node.focused`, which can apply to any number of nodes in a scene graph, and `Scene.focusOwner`, which is the single node in a scene graph that accepts user input. JavaFX 19 added `Node.focusWithin`, which is a flag set on any node that contains a `fo