[Qt-interest] Question regarding QTimer
Tony Rietwyk
tony.rietwyk at rightsoft.com.au
Thu Mar 17 00:18:25 CET 2011
Hi Vesa,
A similar problem used to happen on Windows - but only when the mouse clicks
involved resizing or moving the window.
Tony.
-----Original Message-----
From: qt-interest-bounces+tony.rietwyk=rightsoft.com.au at qt.nokia.com
[mailto:qt-interest-bounces+tony.rietwyk=rightsoft.com.au at qt.nokia.com] On
Behalf Of Vesa Shmuel Peltonen
Sent: Thursday, 17 March 2011 01:39
To: qt-interest at qt.nokia.com
Subject: [Qt-interest] Question regarding QTimer
Hello all,
I've simple question. I'm trying to start a timer when mouse press event is
received on eventfilter:
xxx::eventFilter(QObject *object, QEvent *event)
{
if ( event->type() == QEvent::MouseButtonPress )
{
m_timer->start(150); // msec
...
It seems that the timer timeouts always only after the mouse is released,
even if the mouse press is very long (many seconds).
Is this known behavior and is there way to overcome the problem? Is the
system process blocking the application thread during the mouse press, so
even if the timeout should have happen much earlier, the slot is called only
after the mouse is released?
Btw, my environment is Qt 4.7.2 on S^3 device. I've not tested the behavior
on other platforms.
Thanks,
Vesa
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110317/a51af531/attachment.html
More information about the Qt-interest-old
mailing list