diff --git a/src/openrct2/interface/Window.cpp b/src/openrct2/interface/Window.cpp index e5892c29d2..e0c59c7f6d 100644 --- a/src/openrct2/interface/Window.cpp +++ b/src/openrct2/interface/Window.cpp @@ -916,29 +916,6 @@ static constexpr float kWindowScrollLocations[][2] = { }); } - Viewport* WindowGetPreviousViewport(Viewport* current) - { - bool foundPrevious = (current == nullptr); - for (auto it = g_window_list.rbegin(); it != g_window_list.rend(); it++) - { - auto& w = **it; - if (w.flags & WF_DEAD) - continue; - if (w.viewport != nullptr) - { - if (foundPrevious) - { - return w.viewport; - } - if (w.viewport == current) - { - foundPrevious = true; - } - } - } - return nullptr; - } - void WindowInitAll() { auto* windowMgr = Ui::GetWindowManager(); diff --git a/src/openrct2/interface/Window.h b/src/openrct2/interface/Window.h index 57ecd6b433..233a18bab0 100644 --- a/src/openrct2/interface/Window.h +++ b/src/openrct2/interface/Window.h @@ -333,7 +333,6 @@ namespace OpenRCT2 void TextinputCancel(); - Viewport* WindowGetPreviousViewport(Viewport* current); void WindowInitAll(); void WindowFollowSprite(WindowBase& w, EntityId spriteIndex);