Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-swt-dev] Trouble getting TableItem events

Try :

table.addListener(SWT.MouseDoubleClick, list);

To determine what item received the SWT.MouseDoubleClick see:

http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/platform-swt-home/snippits/snippet110.html

You might also consider using SWT.DefaultSelection instead (a higher level 
event that includes double click but also hitting enter from the keyboard 
when the table has focus - this improves accessibility of your 
application):

        table.addListener(SWT.DefaultSelection, new Listener() {
                public void handleEvent (Event e) {
                        System.out.println("default "+e.item);
                }
        });





"Asif Muhammad" <Asif.Muhammad@xxxxxxx>
Sent by: platform-swt-dev-admin@xxxxxxxxxxx
08/26/2003 11:46 AM
Please respond to platform-swt-dev
 
        To:     <platform-swt-dev@xxxxxxxxxxx>
        cc: 
        Subject:        [platform-swt-dev] Trouble getting TableItem 
events


Hi I want to pickup double click mouse events on TableItem

I do following

item.addListener(SWT.SWT.MouseDoubleClick, list);


And have a listener class

Class MyListener implements Listener{
                 public void handleEvent(Event e){
                                 System.out.println(" Event occurred");
                 }
}


But this does not seem to work 

Any help will be greatly appreciated.

Thanks
Asif
_______________________________________________
platform-swt-dev mailing list
platform-swt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-swt-dev




Back to the top