Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Getting global messages etc.

 
Cer Sir
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI. I'm trying to create a program that will allow the user to press the mouse left button anywhere on the screen, drag, and let go, and the area will be saved to a bitmap or Jpeg image.
Q: How do I capture the mouse moves and get these coordinates properly?
 
khella smith
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u might have to use the mosusemotionlistener's method called mousedragged and the mouselistener's method called mousepressed and mousereleased with the x and y coordinate methods from the mouseevent api to determine the exact point u want that's all i can say and hope it helps
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic