How to implement the transition goal for a SWT browser widget

How to implement the transition goal for a SWT browser widget? Accepting a Browser Instance as a constructor parameter DropTargetdoes not cause notification of registered registered listeners.

    Browser browser = new Browser(parent, SWT.NONE); 
    int operations = DND.DROP_MOVE | DND.DROP_COPY | DND.DROP_DEFAULT; 
    DropTarget target = new DropTarget(browser, operations); 
    target.setTransfer(...) 
    DropTargetListener listener = ...; 
    target.addDropListener(listener); 

Thanks Henry

+5
source share
1 answer

It seems to me that this is not so easy, since the Browser is a collection of custom widgets, see this: http://dev.eclipse.org/mhonarc/lists/platform-swt-dev/msg04523.html

Two workarounds come to my mind:

  • Do it in HTML5, there is DND support
  • : MouseOver , , Drop.
0

All Articles