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

Function hButtonLeft

src/OpenLoco/src/Ui/ScrollView.cpp:335–341  ·  view source on GitHub ↗

0x004C894F

Source from the content-addressed store, hash-verified

333
334 // 0x004C894F
335 static void hButtonLeft(Ui::Window& window, const size_t scrollAreaIndex, const WidgetIndex_t widgetIndex)
336 {
337 window.scrollAreas[scrollAreaIndex].flags |= ScrollFlags::hscrollbarLeftPressed;
338 window.scrollAreas[scrollAreaIndex].contentOffsetX = std::max(window.scrollAreas[scrollAreaIndex].contentOffsetX - kButtonClickStep, 0);
339 ScrollView::updateThumbs(window, widgetIndex);
340 WindowManager::invalidateWidget(window.type, window.number, widgetIndex);
341 }
342
343 // 0x004C89AE
344 static void hButtonRight(Ui::Window& window, const size_t scrollAreaIndex, const WidgetIndex_t widgetIndex)

Callers 2

scrollLeftBeginFunction · 0.85
scrollLeftContinueFunction · 0.85

Calls 2

updateThumbsFunction · 0.85
invalidateWidgetFunction · 0.85

Tested by

no test coverage detected