mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-25 07:44:38 +01:00
Remove common format formatter where possible (#13034)
* Remove common format formatter where possible Eventually should have it limited to tooltips, window titles and widget args * Remove remaining paint functions using common * Remove misuse of gCommonFormatArgs
This commit is contained in:
@@ -351,7 +351,7 @@ static void window_shortcut_scrollpaint(rct_window* w, rct_drawpixelinfo* dpi, i
|
||||
}
|
||||
|
||||
const int32_t bindingOffset = scrollWidth - 150;
|
||||
auto ft = Formatter::Common();
|
||||
auto ft = Formatter();
|
||||
ft.Add<rct_string_id>(STR_SHORTCUT_ENTRY_FORMAT);
|
||||
ft.Add<rct_string_id>(ShortcutList[i].StringId);
|
||||
DrawTextEllipsised(dpi, { 0, y - 1 }, bindingOffset, format, ft, COLOUR_BLACK);
|
||||
@@ -362,7 +362,7 @@ static void window_shortcut_scrollpaint(rct_window* w, rct_drawpixelinfo* dpi, i
|
||||
if (strlen(keybinding) > 0)
|
||||
{
|
||||
const int32_t maxWidth = 150;
|
||||
ft = Formatter::Common();
|
||||
ft = Formatter();
|
||||
ft.Add<rct_string_id>(STR_STRING);
|
||||
ft.Add<char*>(keybinding);
|
||||
DrawTextEllipsised(dpi, { bindingOffset, y - 1 }, maxWidth, format, ft, COLOUR_BLACK);
|
||||
|
||||
Reference in New Issue
Block a user