[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.technology.albireo] Re: Context Help in SwingControl

Gordon Hirsch schrieb:
I've been thinking about this general case a bit. We shouldn't be checking just the direct child for focusability. I've committed a change to CVS that loosens the focusability check to look for *any* child with focusable == true.

I can't tell for sure, but I hope this change would remove the need for your focus listener. It depends on how your Swing component's focus policy is defined.


Hi Gordon,

sorry for my belated reply.
The direct child of the editor extends JScrollPane and its viewport is the (focusable) diagram editor. So that would indeed eliminate my need for the focus listener hack.
Before implementing this hack I thought about removing the outer scrollpane and use a scrollable SWT composite but I came to the conclusion that this would probably mess too much with the Swing editors behaviour (JComponent#setAutoscrolls for example)
I think your change is a good idea, thank you for that.


Best regards,
Johannes