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

Method btnPathPreviewClick

src/Menu/OptionsBattlescapeState.cpp:284–296  ·  view source on GitHub ↗

* Updates the path preview options. * @param action Pointer to an action. */

Source from the content-addressed store, hash-verified

282 * @param action Pointer to an action.
283 */
284void OptionsBattlescapeState::btnPathPreviewClick(Action *)
285{
286 int mode = PATH_NONE;
287 if (_btnArrows->getPressed())
288 {
289 mode |= PATH_ARROWS;
290 }
291 if (_btnTuCost->getPressed())
292 {
293 mode |= PATH_TU_COST;
294 }
295 Options::battleNewPreviewPath = (PathPreview)mode;
296}
297
298/**
299 * Updates the Tooltips option.

Callers

nothing calls this directly

Calls 1

getPressedMethod · 0.80

Tested by

no test coverage detected