From 734ee0f6352fdb6077c142d90f191c11c32f98d2 Mon Sep 17 00:00:00 2001 From: Steph Enders Date: Sun, 26 Jun 2022 21:57:43 -0400 Subject: Alias filesystem library to allow for xp usage MacOS 10.14 still uses experimental/filesystem which is what we're currently targetting. If I can get my hands on a 10.15+ we can test that out --- src/resources/Resources.h | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/resources/Resources.h') diff --git a/src/resources/Resources.h b/src/resources/Resources.h index 21bf8a7..2e0e7c0 100644 --- a/src/resources/Resources.h +++ b/src/resources/Resources.h @@ -30,9 +30,10 @@ #ifdef __APPLE__ #include -namespace std::filesystem = std::experimental::filesystem; +namespace fs = std::experimental::filesystem; #else #include +namespace fs = std::filesystem; #endif #include #include @@ -53,7 +54,7 @@ static const char *DEFAULT_FONT = "PressStart2P-vaV7.ttf"; class Resources { protected: - shared_ptr font; // chosen font + shared_ptr font; // chosen font shared_ptr defaultsLua; // defaults lua file vector fonts; // all found maps vector levels; // all found maps @@ -68,11 +69,11 @@ public: void loadDefaultLuaFile(); vector getFontFiles(); vector getLevels(); - shared_ptr updateFont(int idx); - shared_ptr getFontFile(); - shared_ptr getDefaultsLuaFile(); - shared_ptr getLevelMap(int idx); - optional> getLevelProcLua(int idx); + shared_ptr updateFont(int idx); + shared_ptr getFontFile(); + shared_ptr getDefaultsLuaFile(); + shared_ptr getLevelMap(int idx); + optional> getLevelProcLua(int idx); /* Helper method to convert any path to a const char * * Windows uses wchar_t so this can help provide a common way to * interact with files -- cgit v1.2.3-54-g00ecf