Article View: borland.public.jbuilder.java.api
Article #2287Re: Mouse Event Help!!!
From: Vilasack Phothisan
Date: Fri, 20 Apr 2001 16:27
Date: Fri, 20 Apr 2001 16:27
59 lines
2865 bytes
2865 bytes
okay... I don't know how to word this clearly... What I am trying to do is write a "designer tool" application something like viso. I want to creat these objects call "control" so when I drop a control on a canvas it will pickup when it is clicked etc.. so how do I do it? do I need to create a canvas class that does the painting of all objects? I mean how do I code the canvas to detect the move event stuff? in my applet do I still need a control loop? what would my main program structure look like? I want to create an MDI type of an app. the user would bring up a blank window(canvas) and drop control on it and then move the control around etc... where can I find info to creat apps like this? "Torsten Welches" <torsten.welches@who.cares.netcologne.de> wrote in message news:3adfcc85$1_2@dnews... > > Vilasack, > > if you need an applet you would extend either Applet or JApplet. > Putting a mouseMove method inside the class gets you nothing, > please be sure to understand the event handler concept. > You might want to consider going through a good tutorial, there > are decent ones available online, the most prominent being: > http://java.sun.com/docs/books/tutorial/index.html > > To answer the question about capturing all mouse events: You > would probably don't want to do that with event handler - > override the processMouseEvent method instead... > > Torsten > > "Vilasack Phothisan" <vilasack_phothisan@hotmail.com> wrote: > >How do I create an object that would capture all the mouse events? > > > >I want it to behave like an applet. For example > > > >if I put > >Public Void mouseMove(...) inside the applet class... > >this event will fire when the mouse moves within the applet. > > > >I want the same concept for this object I am trying to create. What class do > >I extend? > > > > > > >
Technical Details
Message-ID:
<3ae0632c$1_1@dnews>Path:
arc1-ca.pugleaf.net!supernews.google.com!newsfeed.google.com!sn-xit-03!supernews.com!logbridge.uoregon.edu!nntp-relay.ihug.net!ihug.co.nz!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnewsReferences:
<3adf47b1_2@dnews> <3adfcc85$1_2@dnews>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,b05d3b3fee2abb19 X-Google-Attributes: gid1089d0,public X-Google-ArrivalTime: 2001-04-20 09:46:06 PST Reply-To: "Vilasack Phothisan" <vilasack_phothisan@hotmail.com> From: "Vilasack Phothisan" <vilasack_phothisan@hotmail.com> Newsgroups: borland.public.jbuilder.java.api References: <3adf47b1_2@dnews> <3adfcc85$1_2@dnews> Subject: Re: Mouse Event Help!!! Date: Fri, 20 Apr 2001 12:27:51 -0400 Lines: 61 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2919.6700 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 NNTP-Posting-Host: 216.120.174.113 Message-ID: <3ae0632c$1_1@dnews> X-Trace: dnews 987783980 216.120.174.113 (20 Apr 2001 09:26:20 -0700) Path: arc1-ca.pugleaf.net!supernews.google.com!newsfeed.google.com!sn-xit-03!supernews.com!logbridge.uoregon.edu!nntp-relay.ihug.net!ihug.co.nz!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnews