CCed to the Dev mailing list where it is perhaps best to continue the discussion (Some context for the Dev list http://apache-pivot-users.399431.n3.nabble.com/KeyListeners-on-ImageView-tp2600622p2600622.html )
On 4 March 2011 11:35, Bill van Melle <[email protected]> wrote: > I shouldn't have to stand on my head creating a focusable subclass of > WindowSkin. (Admittedly, Chris has shown that it's easy to do, but it seems > wrong to make everyone do it.) > I wonder if there is a case to be made for adding a setFocusable(boolean) method to Component which could be used easily to change focusability? Each Component would maintain its current default focusability, but this could be toggled with a simple call to pivotComponent.setFocusable(true/false) rather than the need for sub-classing.. Changing a normally focusable Component to be non-focusable should not cause any problems, but changing a normally non-focusable Component/Container to be focusable would probably mean that there is no graphical indicator that the Component has focus. If a user really needed this they could still create a custom skin which would paint the indicator (or add a conditional Decorator). They could also supply a FocusTraversalPolicy to Containers to meet their individual needs. Chris
