| 45 | #define CURRENT_ENTITY() (game ? CurrentEntity() : nullptr) |
| 46 | |
| 47 | void CLevel::IR_OnMouseWheel(int direction) |
| 48 | { |
| 49 | if (CImGuiEditor::Get().Editor_MouseWheel(direction)) |
| 50 | return; |
| 51 | |
| 52 | if (g_bDisableAllInput) |
| 53 | return; |
| 54 | |
| 55 | if (HUD().GetUI()->IR_OnMouseWheel(direction)) |
| 56 | return; |
| 57 | if (Device.Paused()) |
| 58 | return; |
| 59 | |
| 60 | if (game && Game().IR_OnMouseWheel(direction)) |
| 61 | return; |
| 62 | |
| 63 | if (Actor()) |
| 64 | Actor()->callback(GameObject::eOnMouseWheel)(direction); |
| 65 | |
| 66 | if (HUD().GetUI()->MainInputReceiver()) |
| 67 | return; |
| 68 | if (CURRENT_ENTITY()) |
| 69 | { |
| 70 | IInputReceiver* IR = smart_cast<IInputReceiver*>(smart_cast<CGameObject*>(CURRENT_ENTITY())); |
| 71 | if (IR) |
| 72 | IR->IR_OnMouseWheel(direction); |
| 73 | } |
| 74 | } |
| 75 | |
| 76 | static int mouse_button_2_key[] = {MOUSE_1, MOUSE_2, MOUSE_3, MOUSE_4, MOUSE_5, MOUSE_6, MOUSE_7, MOUSE_8}; |
| 77 |
nothing calls this directly
no test coverage detected