March 30, 2011

MattB MattB
Lab Rat
35 posts

[Solved] Getting simultaneous touch and mouse events in Qt/QML

 

Hello,

My app works great with either touchscreen or mouse, but not both. Is it possible to have both?

To run with a USB mouse:

  1. export QWS_MOUSE_PROTO=IntelliMouse:/dev/input/mouse1
  2. ./myApp -qws

To run with touchscreen:

  1. export QWS_MOUSE_PROTO=tslib:/dev/input/event0
  2. ./myApp -qws

The docs say you can specity multiple devices with QWS_MOUSE_PROTO, but this does not work:

  1. export QWS_MOUSE_PROTO="tslib:/dev/input/event0
  2. IntelliMouse:/dev/input/mouse1"
  3. ./myApp -qws

Is there a way to make a mouse and touchscreen work at the same time?

Thanks,
Matt

1 reply

April 4, 2011

MattB MattB
Lab Rat
35 posts

heh, don’t take the docs too literally! They say to use a line break in the environment variable, but it only works with a single space!!

  1. export QWS_MOUSE_PROTO="tslib:/dev/input/event0 IntelliMouse:/dev/input/mouse1"
  2. ./myApp -qws

 
  ‹‹ QSettings in Qt Simulator: are they actually working?      Font substitution in WinCE ››

You must log in to post a reply. Not a member yet? Register here!