Commit d8d1aaad authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Reset colorwheel slider on right click

Differential revision: https://phabricator.kde.org/D19918
parent ede9ee45
......@@ -166,7 +166,7 @@ void ColorWheel::mousePressEvent(QMouseEvent *event)
if (event->button() == Qt::LeftButton) {
changeColor(colorForPoint(m_lastPoint));
} else {
// reset to default on middle button
// reset to default on middle/right button
qreal r = m_color.redF();
qreal b = m_color.blueF();
qreal g = m_color.greenF();
......@@ -177,7 +177,7 @@ void ColorWheel::mousePressEvent(QMouseEvent *event)
} else if (m_sliderRegion.contains(m_lastPoint)) {
m_isInWheel = false;
m_isInSquare = true;
if (event->button() != Qt::MidButton) {
if (event->button() == Qt::LeftButton) {
changeColor(colorForPoint(m_lastPoint));
} else {
NegQColor c;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment