* Starts scrolling the associated list. * @param action Pointer to an action. * @param state State that the action handlers belong to. */
| 331 | * @param state State that the action handlers belong to. |
| 332 | */ |
| 333 | void ArrowButton::mousePress(Action *action, State *state) |
| 334 | { |
| 335 | ImageButton::mousePress(action, state); |
| 336 | if (_list != 0) |
| 337 | { |
| 338 | if (action->getDetails()->button.button == SDL_BUTTON_LEFT) |
| 339 | { |
| 340 | _timer->start(); |
| 341 | } |
| 342 | else if (action->getDetails()->button.button == SDL_BUTTON_WHEELUP) _list->scrollUp(false, true); |
| 343 | else if (action->getDetails()->button.button == SDL_BUTTON_WHEELDOWN) _list->scrollDown(false, true); |
| 344 | } |
| 345 | } |
| 346 | |
| 347 | /* |
| 348 | * Stops scrolling the associated list. |
nothing calls this directly
no test coverage detected