Active Topics

 


Reply
Thread Tools
mikec's Avatar
Posts: 1,366 | Thanked: 1,185 times | Joined on Jan 2006
#1
The N900 has a touch screen which will always send a mouse pressed event as soon as you have touched the screen.

The widget under the finger will thus grab the mouse events. Any way to disable the mouse press so that you can drag your finger across a number of widgets and have them all pick up the event without having to lift your finger?

kinda like stroking a number of keys on piano, or strumming a number of guitar strings
__________________
N900_Email_Options Wiki Page
 
Posts: 726 | Thanked: 345 times | Joined on Apr 2010 @ Sweden
#2
Just a thought: Create a second window on top of everything, that way you can do the math and send things through if you want to or keep the events and do what you want with them.

Since the N900 uses X11, you need to manage the events on that level, as far as I know. The "window manager" might be able to help, though.
 
Posts: 6 | Thanked: 3 times | Joined on Apr 2010
#3
Reimplement the

void keyPressEvent(QKeyEvent * event)

in each of your widgets and call QWidget::keyPressEvent only if you want the mouse press to do the press.
 

The Following 2 Users Say Thank You to vhs For This Useful Post:
mikec's Avatar
Posts: 1,366 | Thanked: 1,185 times | Joined on Jan 2006
#4
Originally Posted by vhs View Post
Reimplement the

void keyPressEvent(QKeyEvent * event)

in each of your widgets and call QWidget::keyPressEvent only if you want the mouse press to do the press.
thanks for this i had gone down the hard route in moving to qgraphics view, but will look at this later tonight. Maked sense when i think about it, but did not think of the mouse key as a key
__________________
N900_Email_Options Wiki Page
 
mikec's Avatar
Posts: 1,366 | Thanked: 1,185 times | Joined on Jan 2006
#5
Ok tried using qkeypressevent but does not do it. Mouse is still grabbed. Tried mousekeyevent also, but still grabbed.

I have implemented piano keyboard using qgraphics view where I got more control so no problemo.
__________________
N900_Email_Options Wiki Page
 
Reply


 
Forum Jump


All times are GMT. The time now is 13:06.