[Marble-commits] branches/KDE/4.3/kdeedu/marble/src/lib

Ariya Hidayat ariya at kde.org
Thu Jul 30 20:49:45 CEST 2009


SVN commit 1004706 by ariya:

Fix potential divide-by-zero, backported from r1004705.


 M  +1 -1      MarbleWidget.cpp  


--- branches/KDE/4.3/kdeedu/marble/src/lib/MarbleWidget.cpp #1004705:1004706
@@ -797,7 +797,7 @@
     customPaint( &painter );
     d->m_map->d->paintOverlay( painter, dirtyRect );
 
-    qreal fps = 1000.0 / (qreal)( t.elapsed() );
+    qreal fps = 1000.0 / (qreal)( t.elapsed() + 1 );
     d->m_map->d->paintFps( painter, dirtyRect, fps );
     emit d->m_map->framesPerSecond( fps );
 }


More information about the Marble-commits mailing list