| 468 | } |
| 469 | |
| 470 | void InputController::refreshMovementKeyCache() { |
| 471 | for (size_t i = 0; i < input::kToolModeCount; ++i) { |
| 472 | const auto mode = static_cast<input::ToolMode>(i); |
| 473 | auto& mk = movement_keys_per_mode_[i]; |
| 474 | mk.forward = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_FORWARD, mode); |
| 475 | mk.backward = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_BACKWARD, mode); |
| 476 | mk.left = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_LEFT, mode); |
| 477 | mk.right = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_RIGHT, mode); |
| 478 | mk.up = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_UP, mode); |
| 479 | mk.down = bindings_.getKeyForAction(input::Action::CAMERA_MOVE_DOWN, mode); |
| 480 | } |
| 481 | } |
| 482 | |
| 483 | const InputController::MovementKeys& InputController::currentMovementKeys() const { |
| 484 | return movement_keys_per_mode_[static_cast<size_t>(getCurrentToolMode())]; |
nothing calls this directly
no test coverage detected