Article View: borland.public.jbuilder.java.swing
Article #9495Re: Drag and Drop problems
From: Janene McCrillis
Date: Tue, 28 Mar 2000 00:00
Date: Tue, 28 Mar 2000 00:00
27 lines
1672 bytes
1672 bytes
In article <ari1es4ntkirl9gqeueu22ah5bekv9stat@4ax.com>, Rob Wilson <rwilson@compd.com> wrote: > Firstly, all demo's seem to revert to 'text' transfers, I guess I want > to transfer the actual 'networkItem' that the user drags from one cell > into another cell. Is this possible? Yes, it's possible. Read up on the "transferrable" class. You'll create a transferrable object with your networkItem in it to drag it to another cell. You pass it to the startDrag (or is it beginDrag, sorry, code's not in front of me) method in your dragGestureRecognized method. > If anyone has other resources, that would be great, I currently have > javaworlds tutorial, part I and part II. Sun tutorial part I > (couldn't find part II). I used the Graphic Java, Volume I to learn DnD. It does DnD labels, but there was enough there to show me how to extend it to drag other objects. Janene McCrillis Lockheed Martin Space Systems Sent via Deja.com http://www.deja.com/ Before you buy.
Technical Details
Message-ID:
<8br1q9$kq8$1@nnrp1.deja.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<ari1es4ntkirl9gqeueu22ah5bekv9stat@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,5fc6d86dacf3a682 X-Google-Attributes: gid111d45,public From: Janene McCrillis <janene.r.mccrillis@lmco.com> Subject: Re: Drag and Drop problems Date: 2000/03/28 Message-ID: <8br1q9$kq8$1@nnrp1.deja.com> X-Deja-AN: 603531287 References: <ari1es4ntkirl9gqeueu22ah5bekv9stat@4ax.com> X-Http-Proxy: 1.0 x21.deja.com:80 (Squid/1.1.22) for client 204.68.140.35 Organization: Deja.com - Before you buy. X-Article-Creation-Date: Tue Mar 28 19:39:56 2000 GMT X-MyDeja-Info: XMYDJUIDjanene_r_mccrillis Newsgroups: borland.public.jbuilder.java.swing X-Http-User-Agent: Mozilla/4.61 [en] (WinNT; U)