Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » How to open a menu by clicking a button?
How to open a menu by clicking a button? [message #459584] Thu, 11 August 2005 17:04 Go to next message
Eclipse UserFriend
Originally posted by: kevinbrem.discardmail.com

Hi!

I want to show up a drop-down menu by clicking on an additional button
(placed somewhere in a composite). I tried to set the menu visible but
it didn't come up (and checking the visibility afterwards with
isVisible() returned false).
I also tried to open the menu through code, but it wasn't opened either.

If I use the menu in a normal way (by clicking directly on it),
everything works fine.

But how can I achieve to open it via a button (or through the program
directly)?

Thank you for your help!
Cheers, Kevin
Re: How to open a menu by clicking a button? [message #459776 is a reply to message #459584] Tue, 16 August 2005 13:54 Go to previous messageGo to next message
Grant Gayed is currently offline Grant GayedFriend
Messages: 2150
Registered: July 2009
Senior Member
Hi Kevin,

This is not currently supported, I presume because it cannot be implemented
on some platforms. It is also an unusual request, since menus that are
triggered by a user action are most conveniently shown close to where the
mouse already is. In your context would it make sense for you to show a
popup instead that had the same items as the drop-down, so that the user
would not have to mouse over to the shell's top-left corner to access the
drop-down menu?

Grant

"Kevin B." <kevinbrem@discardmail.com> wrote in message
news:ddg0d3$vcv$1@news.eclipse.org...
> Hi!
>
> I want to show up a drop-down menu by clicking on an additional button
> (placed somewhere in a composite). I tried to set the menu visible but
> it didn't come up (and checking the visibility afterwards with
> isVisible() returned false).
> I also tried to open the menu through code, but it wasn't opened either.
>
> If I use the menu in a normal way (by clicking directly on it),
> everything works fine.
>
> But how can I achieve to open it via a button (or through the program
> directly)?
>
> Thank you for your help!
> Cheers, Kevin
Re: How to open a menu by clicking a button? [message #459781 is a reply to message #459776] Tue, 16 August 2005 18:18 Go to previous message
Eclipse UserFriend
Originally posted by: kevinbrem.discardmail.com

Hi Grant!

Grant Gayed schrieb:
> In your context would it make sense for you to show a
> popup instead that had the same items as the drop-down, so that the user
> would not have to mouse over to the shell's top-left corner to access the
> drop-down menu?


Unfortunately a popup-menu is not the solution to my problem.
Nevertheless you helped me with your answer!

If I know, that this isn't possible, that's okay. So I omit it :-)


Thank you!
Kevin
Previous Topic:WizardDialog Questions
Next Topic:Select tablerow based on text in column
Goto Forum:
  


Current Time: Thu Mar 28 08:58:27 GMT 2024

Powered by FUDForum. Page generated in 0.03463 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top