MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / CreateNestedTree

Method CreateNestedTree

src/window.cpp:1799–1803  ·  view source on GitHub ↗

* Perform the first part of the initialization of a nested widget tree. * Construct a nested widget tree in #nested_root, and optionally fill the #widget_lookup array to provide quick access to the uninitialized widgets. * This is mainly useful for setting very basic properties. * @param fill_nested Fill the #widget_lookup (enabling is expensive!). * @note Filling the nested array requires an

Source from the content-addressed store, hash-verified

1797 * @note Filling the nested array requires an additional traversal through the nested widget tree, and is best performed by #FinishInitNested rather than here.
1798 */
1799void Window::CreateNestedTree()
1800{
1801 this->nested_root = MakeWindowNWidgetTree(this->window_desc.nwid_parts, &this->shade_select);
1802 this->nested_root->FillWidgetLookup(this->widget_lookup);
1803}
1804
1805/**
1806 * Perform the second part of the initialization of a nested widget tree.

Callers 15

InitNestedMethod · 0.95
SubsidyListWindowMethod · 0.80
SelectGameWindowMethod · 0.80
SignListWindowMethod · 0.80
SaveLoadWindowMethod · 0.80
ReplaceVehicleWindowMethod · 0.80
GoalListWindowMethod · 0.80
GoalQuestionWindowMethod · 0.80
NewGRFWindowMethod · 0.80

Calls 2

MakeWindowNWidgetTreeFunction · 0.85
FillWidgetLookupMethod · 0.45

Tested by

no test coverage detected