* Close a window by its class and window number (if it is open). * @param cls Window class * @param number Number of the window within the window class * @param force force closing; if false don't close when stickied */
| 1193 | * @param force force closing; if false don't close when stickied |
| 1194 | */ |
| 1195 | void CloseWindowById(WindowClass cls, WindowNumber number, bool force, int data) |
| 1196 | { |
| 1197 | Window *w = FindWindowById(cls, number); |
| 1198 | if (w != nullptr && (force || !w->flags.Test(WindowFlag::Sticky))) { |
| 1199 | w->Close(data); |
| 1200 | } |
| 1201 | } |
| 1202 | |
| 1203 | /** |
| 1204 | * Close all windows of a given class |
no test coverage detected