mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-24 00:53:47 +00:00
Merge pull request #545 from Areloch/AssetFileCaseSensitivityFix
Enforces filename string case sensitivity for assets' internal filenames
This commit is contained in:
commit
0a150e342f
18 changed files with 109 additions and 102 deletions
|
|
@ -188,10 +188,9 @@ void ShapeAsset::initializeAsset()
|
|||
ResourceManager::get().getChangedSignal().notify(this, &ShapeAsset::_onResourceChanged);
|
||||
|
||||
//Ensure our path is expando'd if it isn't already
|
||||
if (!Platform::isFullPath(mFilePath))
|
||||
mFilePath = getOwned() ? expandAssetFilePath(mFileName) : mFilePath;
|
||||
mFilePath = getOwned() ? expandAssetFilePath(mFileName) : mFilePath;
|
||||
|
||||
mConstructorFilePath = expandAssetFilePath(mConstructorFilePath);
|
||||
mConstructorFilePath = getOwned() ? expandAssetFilePath(mConstructorFilePath) : mConstructorFilePath;
|
||||
|
||||
loadShape();
|
||||
}
|
||||
|
|
@ -202,13 +201,13 @@ void ShapeAsset::setShapeFile(const char* pShapeFile)
|
|||
AssertFatal(pShapeFile != NULL, "Cannot use a NULL shape file.");
|
||||
|
||||
// Fetch image file.
|
||||
pShapeFile = StringTable->insert(pShapeFile);
|
||||
pShapeFile = StringTable->insert(pShapeFile, true);
|
||||
|
||||
// Ignore no change,
|
||||
if (pShapeFile == mFileName)
|
||||
return;
|
||||
|
||||
mFileName = pShapeFile;
|
||||
mFileName = getOwned() ? expandAssetFilePath(pShapeFile) : pShapeFile;
|
||||
|
||||
// Refresh the asset.
|
||||
refreshAsset();
|
||||
|
|
@ -220,13 +219,13 @@ void ShapeAsset::setShapeConstructorFile(const char* pShapeConstructorFile)
|
|||
AssertFatal(pShapeConstructorFile != NULL, "Cannot use a NULL shape constructor file.");
|
||||
|
||||
// Fetch image file.
|
||||
pShapeConstructorFile = StringTable->insert(pShapeConstructorFile);
|
||||
pShapeConstructorFile = StringTable->insert(pShapeConstructorFile, true);
|
||||
|
||||
// Ignore no change,
|
||||
if (pShapeConstructorFile == mConstructorFileName)
|
||||
return;
|
||||
|
||||
mConstructorFileName = pShapeConstructorFile;
|
||||
mConstructorFileName = getOwned() ? expandAssetFilePath(pShapeConstructorFile) : pShapeConstructorFile;
|
||||
|
||||
// Refresh the asset.
|
||||
refreshAsset();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue