MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / closeTopmost

Function closeTopmost

src/OpenLoco/src/Ui/WindowManager.cpp:1117–1137  ·  view source on GitHub ↗

0x004BF089

Source from the content-addressed store, hash-verified

1115
1116 // 0x004BF089
1117 void closeTopmost()
1118 {
1119 close(WindowType::dropdown, 0);
1120
1121 for (auto it = _windows.rbegin(); it != _windows.rend(); it++)
1122 {
1123 auto& w = *it;
1124 if (w.hasFlags(WindowFlags::stickToBack))
1125 {
1126 continue;
1127 }
1128
1129 if (w.hasFlags(WindowFlags::stickToFront))
1130 {
1131 continue;
1132 }
1133
1134 close(&w);
1135 break;
1136 }
1137 }
1138
1139 static void windowScrollWheelInput(Ui::Window& window, WidgetIndex_t widgetIndex, int wheel)
1140 {

Callers 1

closeTopmostWindowFunction · 0.85

Calls 4

rbeginMethod · 0.80
rendMethod · 0.80
closeFunction · 0.70
hasFlagsMethod · 0.45

Tested by

no test coverage detected