[Marble-commits] KDE/kdeedu/marble/src/plugins/render/routing
Dennis Nienhüser
earthwings at gentoo.org
Mon Nov 8 21:15:29 CET 2010
SVN commit 1194351 by nienhueser:
Don't jump to invalid positions. Forced repaint must also repaint the marble widget, fixes gps button check state not being updated when clicking on it.
M +3 -0 RoutingPlugin.cpp
--- trunk/KDE/kdeedu/marble/src/plugins/render/routing/RoutingPlugin.cpp #1194350:1194351
@@ -117,6 +117,7 @@
// Trigger a repaint of the float item. Otherwise button state updates are delayed
m_marbleWidget->setAttribute( Qt::WA_NoSystemBackground, false );
m_parent->update();
+ m_marbleWidget->repaint();
bool const mapCoversViewport = m_marbleWidget->viewport()->mapCoversViewport();
m_marbleWidget->setAttribute( Qt::WA_NoSystemBackground, mapCoversViewport );
}
@@ -182,12 +183,14 @@
RouteRequest* request = m_marbleWidget->model()->routingManager()->routeRequest();
if ( request && request->size() > 0 ) {
GeoDataCoordinates source = request->source();
+ if ( source.longitude() != 0.0 || source.latitude() != 0.0 ) {
GeoDataLookAt view;
view.setCoordinates( source );
view.setRange( 750 );
m_marbleWidget->flyTo( view );
}
}
+ }
m_marbleWidget->model()->routingManager()->setGuidanceModeEnabled( enabled );
forceRepaint();
More information about the Marble-commits
mailing list