mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-13 17:43:59 +02:00
Allow clicking on any part of the button
This commit is contained in:
@@ -118,7 +118,7 @@ SlideSwitchButton::mousePressEvent( QMouseEvent* e )
|
||||
void
|
||||
SlideSwitchButton::mouseReleaseEvent( QMouseEvent* e )
|
||||
{
|
||||
const int delta = e->pos().x() - m_mouseDownPos.x();
|
||||
const int delta = m_mouseDownPos.isNull() ? 0 : e->pos().x() - m_mouseDownPos.x();
|
||||
m_mouseDownPos = QPoint();
|
||||
|
||||
// Only act as a real button if the user didn't drag
|
||||
|
Reference in New Issue
Block a user