mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-25 07:44:38 +01:00
Refactor Dropdown to TitleCase (#13352)
* Refactor Dropdown Namespace * Refactor Dropdown to TitleCase
This commit is contained in:
@@ -511,7 +511,7 @@ namespace OpenRCT2::Ui::Windows
|
||||
widget--;
|
||||
auto selectedIndex = widgetDesc->SelectedIndex;
|
||||
const auto& items = widgetDesc->Items;
|
||||
const auto numItems = std::min<size_t>(items.size(), DROPDOWN_ITEMS_MAX_SIZE);
|
||||
const auto numItems = std::min<size_t>(items.size(), Dropdown::ItemsMaxSize);
|
||||
for (size_t i = 0; i < numItems; i++)
|
||||
{
|
||||
gDropdownItemsFormat[i] = selectedIndex == static_cast<int32_t>(i) ? STR_OPTIONS_DROPDOWN_ITEM_SELECTED
|
||||
@@ -519,9 +519,9 @@ namespace OpenRCT2::Ui::Windows
|
||||
auto sz = items[i].c_str();
|
||||
std::memcpy(&gDropdownItemsArgs[i], &sz, sizeof(const char*));
|
||||
}
|
||||
window_dropdown_show_text_custom_width(
|
||||
WindowDropdownShowTextCustomWidth(
|
||||
{ w->windowPos.x + widget->left, w->windowPos.y + widget->top }, widget->height() + 1,
|
||||
w->colours[widget->colour], 0, DROPDOWN_FLAG_STAY_OPEN, numItems, widget->width() - 3);
|
||||
w->colours[widget->colour], 0, Dropdown::Flag::StayOpen, numItems, widget->width() - 3);
|
||||
}
|
||||
else if (widgetDesc->Type == "spinner")
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user