MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / stopScrolling

Method stopScrolling

src/Battlescape/MiniMapView.cpp:398–407  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

396}
397
398void MiniMapView::stopScrolling(Action *action)
399{
400 if (!Options::battleDragScrollInvert)
401 {
402 SDL_WarpMouse(_cursorPosition.x, _cursorPosition.y);
403 action->setMouseAction(_cursorPosition.x/action->getXScale(), _cursorPosition.y/action->getYScale(), _game->getScreen()->getSurface()->getX(), _game->getScreen()->getSurface()->getY());
404 }
405 // reset our "mouse position stored" flag
406 _cursorPosition.z = 0;
407}
408}

Callers

nothing calls this directly

Calls 7

setMouseActionMethod · 0.80
getScreenMethod · 0.80
getXScaleMethod · 0.45
getYScaleMethod · 0.45
getXMethod · 0.45
getSurfaceMethod · 0.45
getYMethod · 0.45

Tested by

no test coverage detected