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

Method hoverRedraw

src/Geoscape/BuildNewBaseState.cpp:201–216  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

199}
200
201void BuildNewBaseState::hoverRedraw(void)
202{
203 double lon, lat;
204 _globe->cartToPolar(_mousex, _mousey, &lon, &lat);
205 if (lon == lon && lat == lat)
206 {
207 _globe->setNewBaseHoverPos(lon,lat);
208 _globe->setNewBaseHover();
209 }
210 if (Options::globeRadarLines && !(AreSame(_oldlat, lat) && AreSame(_oldlon, lon)) )
211 {
212 _oldlat=lat;
213 _oldlon=lon;
214 _globe->invalidate();
215 }
216}
217
218/**
219 * Processes any left-clicks for base placement,

Callers

nothing calls this directly

Calls 5

AreSameFunction · 0.85
cartToPolarMethod · 0.80
setNewBaseHoverPosMethod · 0.80
setNewBaseHoverMethod · 0.80
invalidateMethod · 0.80

Tested by

no test coverage detected