mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-09-21 20:06:40 +00:00
refactor path interface:
- use wrapper class instead of std::wstring (reduces mixing of strings/paths; allows safe+easy join via operator/ and convenient case-insensitive comparison via operator==, avoids NativePathFromString, similar to boost::filesystem) - NativePath -> OsPath - add hash and To/FromJSVal for Path - add TS_ASSERT_PATH_EQUALS - replace _wfopen_s with sys_OpenFile - remove obsolete SortFiles/Directories This was SVN commit r9107.
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
|
||||
#include <map>
|
||||
|
||||
#include "lib/utf8.h"
|
||||
#include "lib/ogl.h"
|
||||
#include "lib/path_util.h"
|
||||
#include "lib/res/graphics/ogl_tex.h"
|
||||
@@ -54,7 +55,7 @@ CTerrainTextureEntry::CTerrainTextureEntry(CTerrainPropertiesPtr props, const Vf
|
||||
for (;it!=m_Groups.end();++it)
|
||||
(*it)->AddTerrain(this);
|
||||
|
||||
m_Tag = CStrW(Path::Basename(path)).ToUTF8();
|
||||
m_Tag = utf8_from_wstring(path.Basename().string());
|
||||
}
|
||||
|
||||
CTerrainTextureEntry::~CTerrainTextureEntry()
|
||||
|
||||
Reference in New Issue
Block a user