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

Method OnInvalidateData

src/network/network_gui.cpp:1724–1731  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1722 }
1723
1724 void OnInvalidateData([[maybe_unused]] int data = 0, [[maybe_unused]] bool gui_scope = true) override
1725 {
1726 this->RebuildList();
1727
1728 /* Currently server information is not synced to clients, so we cannot show it on clients. */
1729 this->GetWidget<NWidgetStacked>(WID_CL_SERVER_SELECTOR)->SetDisplayedPlane(_network_server ? 0 : SZSP_HORIZONTAL);
1730 this->SetWidgetDisabledState(WID_CL_SERVER_NAME_EDIT, !_network_server);
1731 }
1732
1733 void UpdateWidgetSize(WidgetID widget, Dimension &size, [[maybe_unused]] const Dimension &padding, [[maybe_unused]] Dimension &fill, [[maybe_unused]] Dimension &resize) override
1734 {

Callers 1

Calls 3

RebuildListMethod · 0.95
SetDisplayedPlaneMethod · 0.80

Tested by

no test coverage detected