Can I set exclusive grab from an xml file

Questions and answers about 3Dconnexion devices on Windows.

Moderator: Moderators

Post Reply
MarinHobin
Posts: 3
Joined: Sat May 30, 2020 9:21 am

Can I set exclusive grab from an xml file

Post by MarinHobin »

Hi,

I read in the development corner of these forums that in the SDK there is an option to 'exclusive grab' the device. I was wondering if I can set some flag in the .xml config file that is available for each executable?

Cheers, Marin.
jwick
Moderator
Moderator
Posts: 3331
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Re: Can I set exclusive grab from an xml file

Post by jwick »

Yes there is one. There are some restrictions.

<CfgProperties>
<Grab>Hard</Grab> ;Hard as opposed to None

</CfgProperties>

This will grab the connection for just that application while it is running.

This relies on the cfg being read though. If the application doesn't get in focus, the Grab will not be read.

There is one exception to this. The Desktop.xml cfg is always read. If a Grab is in there, the cfg will stay in focus regardless of kb focus.
People typically use this to enable a 2D mouse mode (map the 3D mouse axes and buttons to 2D mouse actions).
There is a ButtonAction that can be used to toggle the Grab in this cfg. The user can assign this to a device button to toggle in and out of 2D mode. E.g., toggle into 2D mode, change focus to a 3D app, toggle into 3D mode, use the app, toggle to 2D mode to move the cursor to a different app, …
Post Reply