ValueDial: fix wheelEvent handling
Signed-off-by: Steve Markgraf <steve@steve-m.de>
This commit is contained in:
parent
664d43351c
commit
7820104666
|
@ -238,10 +238,14 @@ void ValueDial::mouseMoveEvent(QMouseEvent* event)
|
|||
|
||||
void ValueDial::wheelEvent(QWheelEvent* event)
|
||||
{
|
||||
if(m_hightlightedDigit < 0)
|
||||
return;
|
||||
if(m_text[m_hightlightedDigit] == QChar('.'))
|
||||
int i;
|
||||
|
||||
i = (event->x() - 1) / m_digitWidth;
|
||||
if(m_text[i] != QChar('.'))
|
||||
m_hightlightedDigit = i;
|
||||
else
|
||||
return;
|
||||
|
||||
if(m_cursor >= 0) {
|
||||
m_cursor = -1;
|
||||
m_blinkTimer.stop();
|
||||
|
|
Loading…
Reference in New Issue