-rw-r--r-- | korganizer/koagenda.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp index 9720f43..deadfc9 100644 --- a/korganizer/koagenda.cpp +++ b/korganizer/koagenda.cpp | |||
@@ -497,34 +497,35 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me) | |||
497 | } | 497 | } |
498 | endItemAction(); | 498 | endItemAction(); |
499 | } | 499 | } |
500 | } | 500 | } |
501 | 501 | ||
502 | } else { // ---------- viewport() | 502 | } else { // ---------- viewport() |
503 | if (me->button() == LeftButton && mLeftMouseDown ) { //left click | 503 | if (me->button() == LeftButton && mLeftMouseDown ) { //left click |
504 | endSelectAction( true ); // emit new event signal | 504 | endSelectAction( true ); // emit new event signal |
505 | } | 505 | } |
506 | } | 506 | } |
507 | if (me->button() == LeftButton) | 507 | if (me->button() == LeftButton) |
508 | mLeftMouseDown = false; | 508 | mLeftMouseDown = false; |
509 | 509 | ||
510 | break; | 510 | break; |
511 | 511 | ||
512 | case QEvent::MouseMove: | 512 | case QEvent::MouseMove: |
513 | //qDebug("mm "); | ||
513 | if ( !mLeftMouseDown ) | 514 | if ( !mLeftMouseDown ) |
514 | return true; | 515 | return false; |
515 | if ( blockMoving ) { | 516 | if ( blockMoving ) { |
516 | int dX, dY; | 517 | int dX, dY; |
517 | dX = startX - viewportPos.x(); | 518 | dX = startX - viewportPos.x(); |
518 | if ( dX < 0 ) | 519 | if ( dX < 0 ) |
519 | dX = -dX; | 520 | dX = -dX; |
520 | dY = viewportPos.y() - startY; | 521 | dY = viewportPos.y() - startY; |
521 | if ( dY < 0 ) | 522 | if ( dY < 0 ) |
522 | dY = -dY; | 523 | dY = -dY; |
523 | //qDebug("%d %d %d ", dX, dY , blockmoveDist ); | 524 | //qDebug("%d %d %d ", dX, dY , blockmoveDist ); |
524 | if ( dX > blockmoveDist || dY > blockmoveDist ) { | 525 | if ( dX > blockmoveDist || dY > blockmoveDist ) { |
525 | blockMoving = false; | 526 | blockMoving = false; |
526 | } | 527 | } |
527 | } | 528 | } |
528 | if ( ! blockMoving ) | 529 | if ( ! blockMoving ) |
529 | mPopupTimer->stop(); | 530 | mPopupTimer->stop(); |
530 | if (object != viewport()) { | 531 | if (object != viewport()) { |