1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 09:32:12 +01:00

[Fix] Fixing previous commit, it was unable to click on any button.

- Oops...
This commit is contained in:
nowrep 2012-01-09 22:17:05 +01:00
parent eb0d24efd3
commit 03a2b8e991

View File

@ -91,19 +91,20 @@ void ToolButton::mousePressEvent(QMouseEvent* e)
void ToolButton::mouseReleaseEvent(QMouseEvent* e)
{
setDown(false);
if (e->button() == Qt::MiddleButton && rect().contains(e->pos())) {
emit middleMouseClicked();
setDown(false);
return;
}
if (e->button() == Qt::LeftButton && rect().contains(e->pos()) && e->modifiers() == Qt::ControlModifier) {
emit controlClicked();
setDown(false);
return;
}
QToolButton::mouseReleaseEvent(e);
setDown(false);
}
void ToolButton::paintEvent(QPaintEvent* e)