Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

12045 Posts in 1593 Topics- by 593 Members - Latest Member: zhang

26. May 2013, 03:03:45 am
Xith3D CommunityGeneral CategorySupport (Moderator: Marvin Fröhlich)Capture Mouse
Pages: [1]
Print
Author Topic: Capture Mouse  (Read 234 times)
jeffhoye
developers
Enjoying the stay
***
Offline Offline

Posts: 32


View Profile Email
« on: 17. February 2012, 07:46:45 pm »

When I use the default lwjgl Canvas3D by calling
Code:
Canvas3DFactory.createWindowed(800,600,"WidgetTest");

and then call
Code:
canvas.setCursor( null );

then the mouse is captured, and you cant leave the screen without pressing alt-tab.

However, in the Canvas3DPanel I can't find a way to capture the mouse. 

Can you tell me where I can take control of this?  I would like to be able to have a null cursor in the lwjgl frame but also not have the mouse captured.

I also want to be able to capture the mouse in the Canvas3DPanel.

Note, perhaps "Capture" is the wrong terminology.  I always want to receive mouse events if the canvas is focused, but I want to be able to control whether the user can focus on another window with their mouse.

Thanks!
-Jeff
Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #1 on: 18. February 2012, 06:04:30 pm »

Have a look at the JAGaToo mouse classes. They handle this. Though I am not sure, if there's a way to do that in a panel.
Logged
Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic