[MeeGo-touch-dev] Gesture Programming - mouse events?
red dweb
reddweb at gmail.com
Thu Jan 6 15:48:33 PST 2011
You need to call grabgesture for all the gestures you want to handle.
For Mouse, you can simply return "true" (== accept, do nothing) in the
event handler for all mouse events QMouseEvent stuff. You can call
setCursor(Qt::BlankCursor) to make cursor invisible.
If your app inherits from QWidget or other standard classes, you might
want to leave deault mouse event handler alone (for windget exit
button etc). As you will not implement custom mouse events for your
app, they will be automatically be ignored. (use setcursor to make
cursor blankcursor)
On Wed, Jan 5, 2011 at 3:37 PM, Jackson, Thomas (Tom)
<Tom.Jackson at windriver.com> wrote:
>
> Hi All,
>
> I thought it would be good to ask the gesture experts regarding a small issue we are seeing regarding the mouse events instead of gesture events in our gesture programming. We would like to disable/ignore the mouse events and only accept touch gesture events. We have tried to explicitly ignore the mouse events via the Xorg conf file as below.
>
> Section "InputClass"
> Identifier "disable mouse for mtf"
> Driver ""
> MatchDevicePath "/dev/input/mouse*"
> Option "Ignore" "on"
> EndSection
>
> The second step we tried to set up eventFilters to get all the events sent to your object, then filter out the events we are interested in. We still seem to get mouse events rather than gesture/touch events and wondered if anyone can provide us with some quick advice. My question specifically is do we still have to do "grabGesture(Qt:: PinchGesture)" for example to obtain the gesture event and how do we disable mouse events?
>
>
> Thanks in advance.
> Tom
>
>
> _______________________________________________
> MeeGo-touch-dev mailing list
> MeeGo-touch-dev at meego.com
> http://lists.meego.com/listinfo/meego-touch-dev
More information about the MeeGo-touch-dev
mailing list