Skip to content

Commit

Permalink
Fix double-click detection (#62)
Browse files Browse the repository at this point in the history
Fixes #58
  • Loading branch information
grulja authored Mar 19, 2024
1 parent 8aaeb33 commit e3340f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/qadwaitadecorations.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ bool QAdwaitaDecorations::clickButton(Qt::MouseButtons b, Button btn)
bool QAdwaitaDecorations::doubleClickButton(Qt::MouseButtons b, const QPointF &local,
const QDateTime &currentTime)
{
if (b & Qt::LeftButton) {
if (isLeftClicked(b)) {
const qint64 clickInterval = m_lastButtonClick.msecsTo(currentTime);
m_lastButtonClick = currentTime;
const int doubleClickDistance = 5;
Expand Down

0 comments on commit e3340f8

Please sign in to comment.