Skip to content

Commit 6a231fa

Browse files
committed
Geoscape Drag Scroll option ignored
1 parent 7bf6c7d commit 6a231fa

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

src/Geoscape/Globe.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1721,7 +1721,7 @@ void Globe::mouseOver(Action *action, State *state)
17211721
// the mouse-release event is missed for any reason.
17221722
// (checking: is the dragScroll-mouse-button still pressed?)
17231723
// However if the SDL is also missed the release event, then it is to no avail :(
1724-
if (0 == (SDL_GetMouseState(0, 0)&SDL_BUTTON(Options::battleDragScrollButton)))
1724+
if (0 == (SDL_GetMouseState(0, 0)&SDL_BUTTON(Options::globeDragScrollButton)))
17251725
{ // so we missed again the mouse-release :(
17261726
// Check if we have to revoke the scrolling, because it was too short in time, so it was a click
17271727
if ((!_mouseMovedOverThreshold) && (SDL_GetTicks() - _mouseScrollingStartTime <= (Options::dragScrollTimeTolerance)))
@@ -1781,7 +1781,7 @@ void Globe::mousePress(Action *action, State *state)
17811781
// Check for errors
17821782
if (lat == lat && lon == lon)
17831783
{
1784-
if (action->getDetails()->button.button == Options::battleDragScrollButton)
1784+
if (action->getDetails()->button.button == Options::globeDragScrollButton)
17851785
{
17861786
_isMouseScrolling = true;
17871787
_isMouseScrolled = false;
@@ -1842,8 +1842,8 @@ void Globe::mouseClick(Action *action, State *state)
18421842
// (this part handles the release if it is missed and now an other button is used)
18431843
if (_isMouseScrolling)
18441844
{
1845-
if (action->getDetails()->button.button != Options::battleDragScrollButton
1846-
&& 0 == (SDL_GetMouseState(0, 0)&SDL_BUTTON(Options::battleDragScrollButton)))
1845+
if (action->getDetails()->button.button != Options::globeDragScrollButton
1846+
&& 0 == (SDL_GetMouseState(0, 0)&SDL_BUTTON(Options::globeDragScrollButton)))
18471847
{ // so we missed again the mouse-release :(
18481848
// Check if we have to revoke the scrolling, because it was too short in time, so it was a click
18491849
if ((!_mouseMovedOverThreshold) && (SDL_GetTicks() - _mouseScrollingStartTime <= (Options::dragScrollTimeTolerance)))
@@ -1858,7 +1858,7 @@ void Globe::mouseClick(Action *action, State *state)
18581858
if (_isMouseScrolling)
18591859
{
18601860
// While scrolling, other buttons are ineffective
1861-
if (action->getDetails()->button.button == Options::battleDragScrollButton) _isMouseScrolling = false; else return;
1861+
if (action->getDetails()->button.button == Options::globeDragScrollButton) _isMouseScrolling = false; else return;
18621862
// Check if we have to revoke the scrolling, because it was too short in time, so it was a click
18631863
if ((!_mouseMovedOverThreshold) && (SDL_GetTicks() - _mouseScrollingStartTime <= (Options::dragScrollTimeTolerance)))
18641864
{

0 commit comments

Comments
 (0)