|
|
|
Re: how can i show a popup menu on a table column [message #445110 is a reply to message #444858] |
Tue, 26 October 2004 09:11  |
Eclipse User |
|
|
|
Why can't you use a selectionevent for this - even though its from left
mouse click ? We do that in our application ... We save the last used
sort order, and reverse it if clicked more than once!
*/ Lars
Dominik Glaser wrote:
> thanks for your answer,
> but i need this event for sorting the table by this column :(
> have you another idea?
>
> can i register a listener on the parent composite that gets also those
> events,
> that are fired if i click on a child composite of that parent.
>
> dominik
>
>
> Am Thu, 21 Oct 2004 09:43:30 -0400 schrieb Veronika Irvine
> <veronika_irvine@oti.com>:
>
>> Not really supported. No MenuDetect or MouseDown event gets sent for a
>> TableColumn (either from the Table or from the TableColumn) when you
>> click
>> the right mouse button in the header. I think the best you can do is
>> detect a selection of the column header (left mouse) and open the menu
>> as a
>> result:
>>
>> final Menu menu = new Menu(table);
>> MenuItem item2 = new MenuItem(menu, SWT.PUSH);
>> item2.setText("hello");
>> column.addListener(SWT.Selection, new Listener() {
>> public void handleEvent(Event e) {
>> menu.setVisible(true);
>> }
>> });
>>
>> "Dominik Glaser" <dominikg@vr-web.de> wrote in message
>> news:opsf7pu9qbl7b9sl@localhost...
>> hi,
>>
>> i want to show a popup menu, if i click on the table column with the
>> right
>> mouse.
>> is there a possibility to do so.
>>
>> thx
>>
>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.03464 seconds