popups in SWT [message #462158] |
Fri, 07 October 2005 11:44 |
Eclipse User |
|
|
|
Originally posted by: rpuschnik.thegoldensource.com
I programmed a small date picker widget that is displayed in a seperate
shell. By using a seperate shell I can have the date picker "popup"
anywhere I want it to. Now what I want is that the date picker
popup/shell disappears as soon as the user clicks somewhere outside the
shell. I can achieve this by adding a ShellListener to the shell which
closes the shell when the shell gets deactivated. This approach works
fine for Windows.
The problem is that my data picker contains a Combo which allows
choosing the month. In Windows I have no problem selecting the month,
but in Linux/GTK the Combo implementation seems to generate its own
shell for the Combo list upon pressing the arrow button. This results in
triggering the shellDeactivated method on my date-picker-shell which in
turn closes it.:( This makes my current date picker implementation
unuseable for Linux.
I tried to resolve this by adding a listener to the Combo which catches
the event of showing the combo items, but I was not able to find out how
I can catch the button-pressed event of a Combo.
My questions:
1) Is it possible to receive an arrow-button-pressed event of a combobox?
2) Can anyone tell me what the GTK Combo implementation exactly does,
compared to windows?
3) Is there another (better) way in the Eclipse API for displaying
popups in general, instead of using shells directly?
/me is using Eclipse 3.1.0
|
|
|
Powered by
FUDForum. Page generated in 0.02399 seconds