diff options
author | Sami Merila <sami.merila@nokia.com> | 2010-09-21 12:00:30 (GMT) |
---|---|---|
committer | Sami Merila <sami.merila@nokia.com> | 2010-09-21 12:00:30 (GMT) |
commit | c2c8262116550fe679b9f5c09098bd0daac00a5d (patch) | |
tree | dfff670980c54d598d89781f063f40b9f5772145 /src/gui/styles/qs60style.cpp | |
parent | 660ec910ef60513b511e2292255e53701dbb239b (diff) | |
download | Qt-c2c8262116550fe679b9f5c09098bd0daac00a5d.zip Qt-c2c8262116550fe679b9f5c09098bd0daac00a5d.tar.gz Qt-c2c8262116550fe679b9f5c09098bd0daac00a5d.tar.bz2 |
Button remains pressed if release event happens outside of widget
QS60Style tracks the pressed down state for itemviews
and some other widgets that required highlight pressed down graphics.
However, the implementation was faulty as it required that a
mouse release event occurs in another widget, instead of anywhere.
This partially fixes QTBUG-13759.
Task-number: QTBUG-13759
Reviewed-by: Jani Hautakangas
Diffstat (limited to 'src/gui/styles/qs60style.cpp')
-rw-r--r-- | src/gui/styles/qs60style.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp index 5996032..bafc5f3 100644 --- a/src/gui/styles/qs60style.cpp +++ b/src/gui/styles/qs60style.cpp @@ -3436,8 +3436,7 @@ bool QS60Style::eventFilter(QObject *object, QEvent *event) break; } case QEvent::MouseButtonRelease: { - const QWidget *w = QApplication::widgetAt(QCursor::pos()); - if (w && d->m_pressedWidget) { + if (d->m_pressedWidget) { d->m_pressedWidget->update(); d->m_pressedWidget = 0; } |