summaryrefslogtreecommitdiff
path: root/src/resources
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2005-08-25 17:35:44 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2005-08-25 17:35:44 +0000
commit529ba0581833b05921d8dc3336b02a3c6abd511a (patch)
tree0fe12ba22ffef75d2e0ab5729fa86dd48bbbf20b /src/resources
parent9c5199501633ba0e032035a20ef7b9b8e09585cd (diff)
downloadmana-client-529ba0581833b05921d8dc3336b02a3c6abd511a.tar.gz
mana-client-529ba0581833b05921d8dc3336b02a3c6abd511a.tar.bz2
mana-client-529ba0581833b05921d8dc3336b02a3c6abd511a.tar.xz
mana-client-529ba0581833b05921d8dc3336b02a3c6abd511a.zip
Fixed line length in ChangeLog and some other small changes.
Diffstat (limited to 'src/resources')
-rw-r--r--src/resources/image.cpp2
-rw-r--r--src/resources/resourcemanager.cpp13
2 files changed, 6 insertions, 9 deletions
diff --git a/src/resources/image.cpp b/src/resources/image.cpp
index a468bb30..5ea45842 100644
--- a/src/resources/image.cpp
+++ b/src/resources/image.cpp
@@ -70,7 +70,7 @@ Image* Image::load(void* buffer, unsigned int bufferSize)
SDL_RWops *rw = SDL_RWFromMem(buffer, bufferSize);
// Use SDL_Image to load the raw image data and have it free the data
- SDL_Surface* tmpImage = IMG_Load_RW(rw, 1);
+ SDL_Surface *tmpImage = IMG_Load_RW(rw, 1);
if (tmpImage == NULL) {
logger->log("Error, image load failed");
diff --git a/src/resources/resourcemanager.cpp b/src/resources/resourcemanager.cpp
index 8f26cf5c..b443c715 100644
--- a/src/resources/resourcemanager.cpp
+++ b/src/resources/resourcemanager.cpp
@@ -26,11 +26,6 @@
#include <cassert>
#include <physfs.h>
-#ifdef WIN32
-#include <io.h>
-#include <direct.h>
-#endif
-
#include "image.h"
#include "music.h"
#include "soundeffect.h"
@@ -83,10 +78,12 @@ void ResourceManager::searchAndAddArchives(
const char *dirSep = PHYSFS_getDirSeparator();
char **list = PHYSFS_enumerateFiles(path.c_str());
- for (char **i = list; *i != NULL; i++) {
+ for (char **i = list; *i != NULL; i++)
+ {
size_t len = strlen(*i);
- if (len > ext.length() && !ext.compare((*i)+(len - ext.length()))) {
+ if (len > ext.length() && !ext.compare((*i)+(len - ext.length())))
+ {
std::string file, realPath, archive;
file = path + "/" + (*i);
@@ -245,7 +242,7 @@ ResourceManager::loadFile(const std::string &fileName, int &fileSize)
}
// Attempt to open the specified file using PhysicsFS
- PHYSFS_file* file = PHYSFS_openRead(fileName.c_str());
+ PHYSFS_file *file = PHYSFS_openRead(fileName.c_str());
// If the handler is an invalid pointer indicate failure
if (file == NULL) {