mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-24 15:24:30 +01:00
Anchor object load error text to title bar
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
- Fix: [#24371] Fix divide by zero in the scenery window when there is no scenery.
|
||||
- Fix: [#24403] Park fences draw underneath and through opaque water.
|
||||
- Fix: [#24406] The network status window uses an undefined string for its title.
|
||||
- Fix: [#24444] In the object load error window, the guide text overlaps when the title bar is enlarged.
|
||||
|
||||
0.4.22 (2025-05-04)
|
||||
------------------------------------------------------------------------
|
||||
|
||||
@@ -493,16 +493,18 @@ namespace OpenRCT2::Ui::Windows
|
||||
{
|
||||
WindowDrawWidgets(*this, rt);
|
||||
|
||||
auto screenPos = windowPos + ScreenCoordsXY{ 5, widgets[WIDX_TITLE].bottom };
|
||||
|
||||
// Draw explanatory message
|
||||
auto ft = Formatter();
|
||||
ft.Add<StringId>(STR_OBJECT_ERROR_WINDOW_EXPLANATION);
|
||||
DrawTextWrapped(rt, windowPos + ScreenCoordsXY{ 5, 18 }, WW - 10, STR_BLACK_STRING, ft);
|
||||
DrawTextWrapped(rt, screenPos + ScreenCoordsXY{ 0, 4 }, WW - 10, STR_BLACK_STRING, ft);
|
||||
|
||||
// Draw file name
|
||||
ft = Formatter();
|
||||
ft.Add<StringId>(STR_OBJECT_ERROR_WINDOW_FILE);
|
||||
ft.Add<utf8*>(_filePath.c_str());
|
||||
DrawTextEllipsised(rt, { windowPos.x + 5, windowPos.y + 43 }, WW - 5, STR_BLACK_STRING, ft);
|
||||
DrawTextEllipsised(rt, screenPos + ScreenCoordsXY{ 0, 29 }, WW - 5, STR_BLACK_STRING, ft);
|
||||
}
|
||||
|
||||
void OnScrollDraw(const int32_t scrollIndex, RenderTarget& rt) override
|
||||
|
||||
Reference in New Issue
Block a user