MCPcopy Create free account
hub / github.com/OpenRCT2/OpenRCT2 / SetItems

Function SetItems

src/openrct2-ui/interface/Dropdown.h:221–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

219
220 template<int N>
221 void SetItems(const ItemExt (&items)[N])
222 {
223 for (int i = 0; i < N; ++i)
224 {
225 const ItemExt& item = items[i];
226 if (item.itemFormat == kSeparatorString)
227 Ui::Windows::gDropdown.items[i] = Separator();
228 else
229 Ui::Windows::gDropdown.items[i] = ToggleOption(item.stringId);
230 }
231 }
232
233 template<int N>
234 constexpr bool ItemIDsMatchIndices(const ItemExt (&items)[N])

Callers 3

initViewMenuMethod · 0.85
initCheatsMenuMethod · 0.85
BaseMouseDownMethod · 0.85

Calls 2

SeparatorFunction · 0.85
ToggleOptionFunction · 0.70

Tested by

no test coverage detected