[Marble-commits] branches/KDE/4.5/kdeedu/marble/src/lib
Bastian Holst
bastianholst at gmx.de
Sun Jul 11 12:21:22 CEST 2010
SVN commit 1148629 by bholst:
Fixed Marble's wrong spinning direction.
The polarity is not an indicator for the visible pole.
CCBUG: 234861
backport of r1148621
M +3 -1 MarbleWidgetInputHandler.cpp
--- branches/KDE/4.5/kdeedu/marble/src/lib/MarbleWidgetInputHandler.cpp #1148628:1148629
@@ -511,12 +511,14 @@
// Choose spin direction by taking into account whether we
// drag above or below the visible pole.
if ( MarbleWidgetInputHandler::d->m_widget->projection() == Spherical ) {
- if ( polarity > 0 ) {
+ if ( d->m_leftpressedb >= 0 ) {
+ // The visible pole is the north pole
if ( event->y() < ( - MarbleWidgetInputHandler::d->m_widget->northPoleY()
+ MarbleWidgetInputHandler::d->m_widget->height() / 2 ) )
d->m_leftpresseddirection = -1;
}
else {
+ // The visible pole is the south pole
if ( event->y() > ( + MarbleWidgetInputHandler::d->m_widget->northPoleY()
+ MarbleWidgetInputHandler::d->m_widget->height() / 2 ) )
d->m_leftpresseddirection = -1;
More information about the Marble-commits
mailing list