Hi all,
Here is what I found so far:
- It looks that there is no problem in java-gnome: ComboBox as Button
both extend Bin, and Button is working properly. No code in the
hierarchy captures the signal or prevents emiting it.
- Attaching a ContainerListener to the ComboBox gives you a
SET_FOCUS_CHILD event, while doing the same in the Button doesn't.
- Looking at the gtk code, it looks that the combobox grabs the focus to
some of his childrens, so the combobox itself never gets focus, and
doesn't emit a focus signal itself.
- Writing a similar example in C gives the same results: the Button
emits the focus out event and the ComboBox doesn't.
- I'm left to using the SET_FOCUS_CHILD of the Container when using a
ComboBox.
- It remains for more experienced people to decide if this is a bug /
design decision from GTK, and people should use SET_FOCUS_CHILD (and we
need to document it :)).
Examples attached.
See you!
Andrew Cowie wrote:
> On Wed, 2006-08-02 at 11:50 +0100, Manuel Clos wrote:
>> Here is a compact example, showing that Entry produces focus events,
>> while ComboBox doesn't.
>
> Duplicated.
>
> Manuel, chat with the day-shift guys in Toronto on IRC, but if none of
> them are able to figure this one out quickly, I'd suggest you raise a
> bug in Bugzilla (against java-gnome/libgtk-java) and attach your test
> case.
|