Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Handling the Event of the Image

 
Sathish Babu Adluru Subas
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Javacs,
In my Applet,I have an image at top and a panel at the bottom.what i want to do is that when i double-click(or whatever) on the image,i want to trap the event and display the same image in the empty panel provided for displaying the image.
how can i do this? help me out,please!!!
 
Jesper Ottosson
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
umm, first of all, in which component is the image drawn? lets say that you have a panel myPanel, in which the image is drawn, and fully covers. then the code would be

and then, in the paint method of the second panel, you paint the image if paintOnSecondPanel is true...
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic