diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-03-21 21:56:12 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-03-21 21:56:12 +0000 |
commit | 823aa330987205b251d9f662cfdd4c39149c6ec7 (patch) | |
tree | 55e78b4621bfc867b5ff1ecee101d46a6d7169e2 /src/resources/resourcemanager.cpp | |
parent | 9d51b2e1077042ae42d42a0e6314e439c62e2925 (diff) | |
download | mana-823aa330987205b251d9f662cfdd4c39149c6ec7.tar.gz mana-823aa330987205b251d9f662cfdd4c39149c6ec7.tar.bz2 mana-823aa330987205b251d9f662cfdd4c39149c6ec7.tar.xz mana-823aa330987205b251d9f662cfdd4c39149c6ec7.zip |
Renamed Spriteset to ImageSet.
Diffstat (limited to 'src/resources/resourcemanager.cpp')
-rw-r--r-- | src/resources/resourcemanager.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/resources/resourcemanager.cpp b/src/resources/resourcemanager.cpp index 37a82b0c..985c11dd 100644 --- a/src/resources/resourcemanager.cpp +++ b/src/resources/resourcemanager.cpp @@ -31,7 +31,7 @@ #include "image.h" #include "music.h" #include "soundeffect.h" -#include "spriteset.h" +#include "imageset.h" #include "spritedef.h" #include "../log.h" @@ -46,7 +46,7 @@ ResourceManager::ResourceManager() ResourceManager::~ResourceManager() { - // Release any remaining spritedefs first because they depend on spritesets + // Release any remaining spritedefs first because they depend on image sets ResourceIterator iter = mResources.begin(); while (iter != mResources.end()) { @@ -63,11 +63,11 @@ ResourceManager::~ResourceManager() } } - // Release any remaining spritesets first because they depend on images + // Release any remaining image sets first because they depend on images iter = mResources.begin(); while (iter != mResources.end()) { - if (dynamic_cast<Spriteset*>(iter->second) != 0) + if (dynamic_cast<ImageSet*>(iter->second) != 0) { cleanUp(iter->second); ResourceIterator toErase = iter; @@ -229,8 +229,8 @@ ResourceManager::getSoundEffect(const std::string &idPath) return dynamic_cast<SoundEffect*>(get(SOUND_EFFECT, idPath)); } -Spriteset* -ResourceManager::getSpriteset(const std::string &imagePath, int w, int h) +ImageSet* +ResourceManager::getImageSet(const std::string &imagePath, int w, int h) { std::stringstream ss; ss << imagePath << "[" << w << "x" << h << "]"; @@ -240,7 +240,7 @@ ResourceManager::getSpriteset(const std::string &imagePath, int w, int h) if (resIter != mResources.end()) { resIter->second->incRef(); - return dynamic_cast<Spriteset*>(resIter->second); + return dynamic_cast<ImageSet*>(resIter->second); } Image *img = getImage(imagePath); @@ -249,13 +249,13 @@ ResourceManager::getSpriteset(const std::string &imagePath, int w, int h) return NULL; } - Spriteset *spriteset = new Spriteset(idPath, img, w, h); - spriteset->incRef(); - mResources[idPath] = spriteset; + ImageSet *imageSet = new ImageSet(idPath, img, w, h); + imageSet->incRef(); + mResources[idPath] = imageSet; img->decRef(); - return spriteset; + return imageSet; } SpriteDef* |