Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Drag and Drop from view to editor
Drag and Drop from view to editor [message #506383] Thu, 07 January 2010 06:22 Go to next message
Eclipse UserFriend
Hi all,

I'm doing a POC to convert an existing RCP application to RAP.
The drag and drop feature works well when I drag elements from a view and drop some to an other view but it doesn't work when I drop them to an editor.

The code responsible of drop is the same in the view and the editor.
Table t = new Table(parent, SWT.NONE);
TableViewer tViewer = new TableViewer(t);
tViewer.addDropSupport(DND.DROP_MOVE | DND.DROP_COPY, new Transfer[] { ObjectTransfer.getInstance() }, new DefaultDropTargetListener());

And I get the following exception:
java.lang.ArrayIndexOutOfBoundsException: 0
at org.eclipse.swt.internal.widgets.displaykit.DNDSupport.proce ssDragEnter(DNDSupport.java:161)
at org.eclipse.swt.internal.widgets.displaykit.DNDSupport.acces s$3(DNDSupport.java:147)
at org.eclipse.swt.internal.widgets.displaykit.DNDSupport$1.run (DNDSupport.java:119)
at org.eclipse.rwt.lifecycle.ProcessActionRunner.executeNext(Pr ocessActionRunner.java:57)
at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.readAndDispa tch(RWTLifeCycle.java:238)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :982)

I'm using eclipse 3.6M3 and RAP 1.3M4.
Has somebody tried to drag and drop elements from view to editor?
Do you have any idea about my bug?

Thanks in advance
Florent Métral
Re: Drag and Drop from view to editor [message #506409 is a reply to message #506383] Thu, 07 January 2010 08:06 Go to previous messageGo to next message
Eclipse UserFriend
Hi Florent,

it looks like a bug. Please file a bugzilla [1] with a small snippet to
reproduce it.

[1] http://eclipse.org/rap/bugs.php

Best,
Ivan

On 1/7/2010 1:22 PM, fmetral@sopragroup.com wrote:
> Hi all,
>
> I'm doing a POC to convert an existing RCP application to RAP.
> The drag and drop feature works well when I drag elements from a view
> and drop some to an other view but it doesn't work when I drop them to
> an editor.
>
> The code responsible of drop is the same in the view and the editor.
> Table t = new Table(parent, SWT.NONE);
> TableViewer tViewer = new TableViewer(t);
> tViewer.addDropSupport(DND.DROP_MOVE | DND.DROP_COPY, new Transfer[] {
> ObjectTransfer.getInstance() }, new DefaultDropTargetListener());
>
> And I get the following exception:
> java.lang.ArrayIndexOutOfBoundsException: 0
> at org.eclipse.swt.internal.widgets.displaykit.DNDSupport.proce
> ssDragEnter(DNDSupport.java:161)
> at org.eclipse.swt.internal.widgets.displaykit.DNDSupport.acces
> s$3(DNDSupport.java:147)
> at org.eclipse.swt.internal.widgets.displaykit.DNDSupport$1.run
> (DNDSupport.java:119)
> at org.eclipse.rwt.lifecycle.ProcessActionRunner.executeNext(Pr
> ocessActionRunner.java:57)
> at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.readAndDispa
> tch(RWTLifeCycle.java:238)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java
> :982)
>
> I'm using eclipse 3.6M3 and RAP 1.3M4.
> Has somebody tried to drag and drop elements from view to editor?
> Do you have any idea about my bug?
>
> Thanks in advance
> Florent Métral
Re: Drag and Drop from view to editor [message #506419 is a reply to message #506409] Thu, 07 January 2010 08:29 Go to previous message
Eclipse UserFriend
Thanks a lot Ivan.
I've filed the bug 299034
Regards,
Florent Métral
Previous Topic:Problem with TableViewer in Column/Table/Browser resizing and scroll bar event.
Next Topic:Design implementation issue [Fancy, Business]
Goto Forum:
  


Current Time: Sun Jul 06 11:49:45 EDT 2025

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

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

Back to the top