| 47 | } |
| 48 | |
| 49 | void Mouse::Update() { |
| 50 | wheel_delta_x_ = 0; |
| 51 | wheel_delta_y_ = 0; |
| 52 | for (int& i : delta_) { |
| 53 | i = 0; |
| 54 | } |
| 55 | for (int i = 0; i < NUM_BUTTONS; ++i) { |
| 56 | mouse_double_click_[i] = false; |
| 57 | if (mouse_down_[i] == CLICKED) { |
| 58 | mouse_down_[i] = HELD; |
| 59 | } |
| 60 | } |
| 61 | } |
| 62 | |
| 63 | void Mouse::MouseWheelEvent(int x_amount, int y_amount) { |
| 64 | wheel_delta_x_ += x_amount; |