Currently a node can receive a focus if it is both focusable and has at least one key event handler attached to it and all nodes are focusable by default. These two things come as a surprise to quite a few users. Many do not agree that a key listener is a requirement for a node to be focusable.
To improve this I suggest the following changes:
node is not focusable by default and key handler is not required for a node to get focused.
there are two exceptions to this: Control and SwingComponent are to be focusable by default.
the suggested patch is in the attachment
IMPORTANT: this change is not backward compatible
To improve this I suggest the following changes:
node is not focusable by default and key handler is not required for a node to get focused.
there are two exceptions to this: Control and SwingComponent are to be focusable by default.
the suggested patch is in the attachment
IMPORTANT: this change is not backward compatible