MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / onMouseDown

Function onMouseDown

src/OpenLoco/src/Ui/Windows/Options.cpp:456–476  ·  view source on GitHub ↗

0x004BFBB7

Source from the content-addressed store, hash-verified

454
455 // 0x004BFBB7
456 static void onMouseDown(Window& self, WidgetIndex_t wi, [[maybe_unused]] const WidgetId id)
457 {
458 switch (wi)
459 {
460 case Widx::screen_mode_btn:
461 screenModeMouseDown(self, wi);
462 break;
463 case Widx::display_resolution_btn:
464 resolutionMouseDown(self, wi);
465 break;
466 case Widx::display_scale_down_btn:
467 displayScaleMouseDown(self, wi, -OpenLoco::Ui::ScaleFactor::step);
468 break;
469 case Widx::display_scale_up_btn:
470 displayScaleMouseDown(self, wi, OpenLoco::Ui::ScaleFactor::step);
471 break;
472 case Widx::frame_limit_btn:
473 frameLimitMouseDown(self, wi);
474 break;
475 }
476 }
477
478 // 0x004BFBE8
479 static void onDropdown(Window& self, WidgetIndex_t wi, [[maybe_unused]] const WidgetId id, int16_t item_index)

Callers

nothing calls this directly

Calls 15

screenModeMouseDownFunction · 0.85
resolutionMouseDownFunction · 0.85
displayScaleMouseDownFunction · 0.85
frameLimitMouseDownFunction · 0.85
vehicleZoomMouseDownFunction · 0.85
audioDeviceMouseDownFunction · 0.85
volumeSliderMouseDownFunction · 0.85
languageMouseDownFunction · 0.85
heightsLabelsMouseDownFunction · 0.85

Tested by

no test coverage detected