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

Method handle

src/Battlescape/MiniMapState.cpp:106–120  ·  view source on GitHub ↗

* Handles mouse-wheeling. * @param action Pointer to an action. */

Source from the content-addressed store, hash-verified

104 * @param action Pointer to an action.
105 */
106void MiniMapState::handle(Action *action)
107{
108 State::handle(action);
109 if (action->getDetails()->type == SDL_MOUSEBUTTONDOWN)
110 {
111 if (action->getDetails()->button.button == SDL_BUTTON_WHEELUP)
112 {
113 btnLevelUpClick(action);
114 }
115 else if (action->getDetails()->button.button == SDL_BUTTON_WHEELDOWN)
116 {
117 btnLevelDownClick(action);
118 }
119 }
120}
121
122/**
123 * Returns to the previous screen.

Callers 1

mouseOverMethod · 0.45

Calls 1

getDetailsMethod · 0.80

Tested by

no test coverage detected