1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-18 12:33:17 +01:00

Refactor get_file_extension_type()

This commit is contained in:
Michael Steenbeek
2022-01-27 12:14:19 +01:00
committed by GitHub
parent 3359dc4509
commit 2c8c940caa
6 changed files with 61 additions and 64 deletions

View File

@@ -228,17 +228,17 @@ namespace Editor
// after we have loaded a new park.
window_close_all();
uint32_t extension = get_file_extension_type(path);
auto extension = get_file_extension_type(path);
switch (extension)
{
case FILE_EXTENSION_SC6:
case FILE_EXTENSION_SV6:
case FileExtension::SC6:
case FileExtension::SV6:
return ReadS6(path);
case FILE_EXTENSION_SC4:
case FileExtension::SC4:
return LoadLandscapeFromSC4(path);
case FILE_EXTENSION_SV4:
case FileExtension::SV4:
return LoadLandscapeFromSV4(path);
case FILE_EXTENSION_PARK:
case FileExtension::PARK:
return ReadPark(path);
default:
return false;