| 274 | } |
| 275 | |
| 276 | bool LoadLandscape(const utf8* path) |
| 277 | { |
| 278 | // #4996: Make sure the object selection window closes here to prevent unload objects |
| 279 | // after we have loaded a new park. |
| 280 | auto* windowMgr = Ui::GetWindowManager(); |
| 281 | windowMgr->CloseAll(); |
| 282 | |
| 283 | if (!GetContext()->LoadParkFromFile(path)) |
| 284 | return false; |
| 285 | |
| 286 | auto extension = Path::GetExtension(path); |
| 287 | bool loadedFromSave = !ParkImporter::ExtensionIsScenario(extension); |
| 288 | |
| 289 | AfterLoadCleanup(loadedFromSave); |
| 290 | return true; |
| 291 | } |
| 292 | |
| 293 | static void ClearMapForEditing(bool fromSave) |
| 294 | { |
nothing calls this directly
no test coverage detected