[Marble-commits] KDE/kdeedu/marble/src/lib/routing

Dennis Nienhüser earthwings at gentoo.org
Sun May 2 16:59:46 CEST 2010


SVN commit 1121864 by nienhueser:

Repaint route region also when cancelling via point creation.

 M  +2 -2      RoutingLayer.cpp  


--- trunk/KDE/kdeedu/marble/src/lib/routing/RoutingLayer.cpp #1121863:1121864
@@ -426,17 +426,17 @@
             m_routeSkeleton->setPosition( m_movingIndex, moved );
             m_marbleWidget->setCursor( Qt::ArrowCursor );
         } else if ( !m_dragStopOver.isNull() ) {
-            if ( e->buttons() & Qt::LeftButton ) {
                 // Repaint only that region of the map that is affected by the change
                 QRect dirty = m_routeRegion.boundingRect();
                 dirty |= QRect( m_dropStopOver, QSize( 22, 22 ) );
                 dirty |= QRect( e->pos(), QSize( 22, 22 ) );
+            if ( e->buttons() & Qt::LeftButton ) {
                 m_dropStopOver = e->pos();
-                m_marbleWidget->repaint( dirty );
             } else {
                 m_dragStopOver = QPoint();
                 m_dropStopOver = QPoint();
             }
+            m_marbleWidget->repaint( dirty );
             m_marbleWidget->setCursor( Qt::ArrowCursor );
         } else if ( isInfoPoint( e->pos() ) ) {
             clearStopOver();


More information about the Marble-commits mailing list