mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-28 09:14:58 +01:00
Move more Ui functions to Ui library (#22444)
* Move various methods into the ui library * Move various zoom functions to ui
This commit is contained in:
@@ -11,18 +11,6 @@ void WindowBase::SetLocation(const CoordsXYZ& coords)
|
||||
flags &= ~WF_SCROLLING_TO_LOCATION;
|
||||
}
|
||||
|
||||
void WindowBase::ScrollToViewport()
|
||||
{
|
||||
if (viewport == nullptr || !focus.has_value())
|
||||
return;
|
||||
|
||||
CoordsXYZ newCoords = focus.value().GetPos();
|
||||
|
||||
auto mainWindow = WindowGetMain();
|
||||
if (mainWindow != nullptr)
|
||||
WindowScrollToLocation(*mainWindow, newCoords);
|
||||
}
|
||||
|
||||
void WindowBase::Invalidate()
|
||||
{
|
||||
GfxSetDirtyBlocks({ windowPos, windowPos + ScreenCoordsXY{ width, height } });
|
||||
|
||||
Reference in New Issue
Block a user