Skip to main content



      Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » How to make a custom drag and drop tracker image
How to make a custom drag and drop tracker image [message #449221] Wed, 19 January 2005 13:12 Go to next message
Eclipse UserFriend
Hi,

I want to drag a tree item to the editor. I want to tracker image showing
the actual size of the object being dropped. Just like when you move a
control, it shows the tracker with the actual size of the object moved.

Could someone tell me how to do it or which classes I should look at?

Thanks,

Kevin
Re: How to make a custom drag and drop tracker image [message #449287 is a reply to message #449221] Thu, 20 January 2005 10:30 Go to previous messageGo to next message
Eclipse UserFriend
This is not currently supported with DragSource/DropTarget. This is a
requirement that I am investigating but I can not give a date when this will
be available.

You could use org.eclipse.swt.widgets.Tracker and implement your own
DragDetect listener.

"Kevin" <kevinlouisnospam@hotmail.com> wrote in message
news:csm7vb$8mq$1@www.eclipse.org...
> Hi,
>
> I want to drag a tree item to the editor. I want to tracker image showing
> the actual size of the object being dropped. Just like when you move a
> control, it shows the tracker with the actual size of the object moved.
>
> Could someone tell me how to do it or which classes I should look at?
>
> Thanks,
>
> Kevin
>
>
Re: How to make a custom drag and drop tracker image [message #449308 is a reply to message #449287] Thu, 20 January 2005 20:17 Go to previous messageGo to next message
Eclipse UserFriend
Could you tell me how it can be done? I look at the DragSource.drag
function, it uses the COM.DoDragDrop to do the drag drop. I don't know
where I can set the Tracker.

Thanks.

"Veronika Irvine" <veronika_irvine@oti.com> wrote in message
news:csoir4$3so$1@www.eclipse.org...
> This is not currently supported with DragSource/DropTarget. This is a
> requirement that I am investigating but I can not give a date when this
will
> be available.
>
> You could use org.eclipse.swt.widgets.Tracker and implement your own
> DragDetect listener.
>
> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
> news:csm7vb$8mq$1@www.eclipse.org...
> > Hi,
> >
> > I want to drag a tree item to the editor. I want to tracker image
showing
> > the actual size of the object being dropped. Just like when you move a
> > control, it shows the tracker with the actual size of the object moved.
> >
> > Could someone tell me how to do it or which classes I should look at?
> >
> > Thanks,
> >
> > Kevin
> >
> >
>
>
Re: How to make a custom drag and drop tracker image [message #449314 is a reply to message #449308] Fri, 21 January 2005 07:02 Go to previous messageGo to next message
Eclipse UserFriend
You can not do it using DragSource. You must implement your own mouse event
handlers to simulate drag and drop. This is how Eclipse allows you to drag
views around the workbench. It does not use DragSource and DropTarget, it
uses DragDetect, MouseEnter, MouseMove, MouseExit events etc.


"Kevin" <kevinlouisnospam@hotmail.com> wrote in message
news:cspl82$v4g$1@www.eclipse.org...
> Could you tell me how it can be done? I look at the DragSource.drag
> function, it uses the COM.DoDragDrop to do the drag drop. I don't know
> where I can set the Tracker.
>
> Thanks.
>
> "Veronika Irvine" <veronika_irvine@oti.com> wrote in message
> news:csoir4$3so$1@www.eclipse.org...
>> This is not currently supported with DragSource/DropTarget. This is a
>> requirement that I am investigating but I can not give a date when this
> will
>> be available.
>>
>> You could use org.eclipse.swt.widgets.Tracker and implement your own
>> DragDetect listener.
>>
>> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
>> news:csm7vb$8mq$1@www.eclipse.org...
>> > Hi,
>> >
>> > I want to drag a tree item to the editor. I want to tracker image
> showing
>> > the actual size of the object being dropped. Just like when you move a
>> > control, it shows the tracker with the actual size of the object moved.
>> >
>> > Could someone tell me how to do it or which classes I should look at?
>> >
>> > Thanks,
>> >
>> > Kevin
>> >
>> >
>>
>>
>
>
Re: How to make a custom drag and drop tracker image [message #449452 is a reply to message #449314] Mon, 24 January 2005 13:04 Go to previous messageGo to next message
Eclipse UserFriend
Hi Veronika,

I cannot find the DragDetect function in SWT. Could you tell me which file
I should look at?

Thanks.

Kevin

"Veronika Irvine" <veronika_irvine@oti.com> wrote in message
news:csqr0n$b6k$1@www.eclipse.org...
> You can not do it using DragSource. You must implement your own mouse
event
> handlers to simulate drag and drop. This is how Eclipse allows you to
drag
> views around the workbench. It does not use DragSource and DropTarget, it
> uses DragDetect, MouseEnter, MouseMove, MouseExit events etc.
>
>
> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
> news:cspl82$v4g$1@www.eclipse.org...
> > Could you tell me how it can be done? I look at the DragSource.drag
> > function, it uses the COM.DoDragDrop to do the drag drop. I don't know
> > where I can set the Tracker.
> >
> > Thanks.
> >
> > "Veronika Irvine" <veronika_irvine@oti.com> wrote in message
> > news:csoir4$3so$1@www.eclipse.org...
> >> This is not currently supported with DragSource/DropTarget. This is a
> >> requirement that I am investigating but I can not give a date when this
> > will
> >> be available.
> >>
> >> You could use org.eclipse.swt.widgets.Tracker and implement your own
> >> DragDetect listener.
> >>
> >> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
> >> news:csm7vb$8mq$1@www.eclipse.org...
> >> > Hi,
> >> >
> >> > I want to drag a tree item to the editor. I want to tracker image
> > showing
> >> > the actual size of the object being dropped. Just like when you move
a
> >> > control, it shows the tracker with the actual size of the object
moved.
> >> >
> >> > Could someone tell me how to do it or which classes I should look at?
> >> >
> >> > Thanks,
> >> >
> >> > Kevin
> >> >
> >> >
> >>
> >>
> >
> >
>
>
Re: How to make a custom drag and drop tracker image [message #449479 is a reply to message #449452] Tue, 25 January 2005 07:50 Go to previous message
Eclipse UserFriend
control.addListener(SWT.DragDetect, new Listener() {
public void handleEvent(Event e) {
// code to start using Tracker.
}
});

"Kevin" <kevinlouisnospam@hotmail.com> wrote in message
news:ct3dc4$mea$1@www.eclipse.org...
> Hi Veronika,
>
> I cannot find the DragDetect function in SWT. Could you tell me which
> file
> I should look at?
>
> Thanks.
>
> Kevin
>
> "Veronika Irvine" <veronika_irvine@oti.com> wrote in message
> news:csqr0n$b6k$1@www.eclipse.org...
>> You can not do it using DragSource. You must implement your own mouse
> event
>> handlers to simulate drag and drop. This is how Eclipse allows you to
> drag
>> views around the workbench. It does not use DragSource and DropTarget,
>> it
>> uses DragDetect, MouseEnter, MouseMove, MouseExit events etc.
>>
>>
>> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
>> news:cspl82$v4g$1@www.eclipse.org...
>> > Could you tell me how it can be done? I look at the DragSource.drag
>> > function, it uses the COM.DoDragDrop to do the drag drop. I don't know
>> > where I can set the Tracker.
>> >
>> > Thanks.
>> >
>> > "Veronika Irvine" <veronika_irvine@oti.com> wrote in message
>> > news:csoir4$3so$1@www.eclipse.org...
>> >> This is not currently supported with DragSource/DropTarget. This is a
>> >> requirement that I am investigating but I can not give a date when
>> >> this
>> > will
>> >> be available.
>> >>
>> >> You could use org.eclipse.swt.widgets.Tracker and implement your own
>> >> DragDetect listener.
>> >>
>> >> "Kevin" <kevinlouisnospam@hotmail.com> wrote in message
>> >> news:csm7vb$8mq$1@www.eclipse.org...
>> >> > Hi,
>> >> >
>> >> > I want to drag a tree item to the editor. I want to tracker image
>> > showing
>> >> > the actual size of the object being dropped. Just like when you
>> >> > move
> a
>> >> > control, it shows the tracker with the actual size of the object
> moved.
>> >> >
>> >> > Could someone tell me how to do it or which classes I should look
>> >> > at?
>> >> >
>> >> > Thanks,
>> >> >
>> >> > Kevin
>> >> >
>> >> >
>> >>
>> >>
>> >
>> >
>>
>>
>
>
Previous Topic:JFace Table - truncated image size in ITableLabelProvider
Next Topic:activeEditorPart is always null (setActivePage)
Goto Forum:
  


Current Time: Wed Jul 23 13:44:40 EDT 2025

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

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

Back to the top