summaryrefslogtreecommitdiff
path: root/src/resources/resourcemanager.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-09-04 23:47:11 +0300
committerAndrei Karas <akaras@inbox.ru>2012-09-04 23:47:11 +0300
commitf24ddad3fa0f843eb29a281426151cf1a5f31f4b (patch)
tree6f3faaf38f069f1e88435b7c976ff4070b7a1dcb /src/resources/resourcemanager.h
parent3a407bb6b73a186eafd99bcec570f88097c4b2e1 (diff)
downloadmanaplus-f24ddad3fa0f843eb29a281426151cf1a5f31f4b.tar.gz
manaplus-f24ddad3fa0f843eb29a281426151cf1a5f31f4b.tar.bz2
manaplus-f24ddad3fa0f843eb29a281426151cf1a5f31f4b.tar.xz
manaplus-f24ddad3fa0f843eb29a281426151cf1a5f31f4b.zip
add const to more classes,
fix other small style issues.
Diffstat (limited to 'src/resources/resourcemanager.h')
-rw-r--r--src/resources/resourcemanager.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/resources/resourcemanager.h b/src/resources/resourcemanager.h
index 540e5f882..dee7f5459 100644
--- a/src/resources/resourcemanager.h
+++ b/src/resources/resourcemanager.h
@@ -56,7 +56,7 @@ class ResourceManager
public:
typedef Resource *(*loader)(SDL_RWops *);
- typedef Resource *(*generator)(void *);
+ typedef Resource *(*generator)(const void *const);
ResourceManager();
@@ -95,13 +95,13 @@ class ResourceManager
*/
void searchAndAddArchives(const std::string &path,
const std::string &ext,
- const bool append);
+ const bool append) const;
/**
* Searches for zip files and remove them from the search path.
*/
void searchAndRemoveArchives(const std::string &path,
- const std::string &ext);
+ const std::string &ext) const;
/**
* Creates a directory in the write path
@@ -142,7 +142,8 @@ class ResourceManager
* @return A valid resource or <code>NULL</code> if the resource could
* not be generated.
*/
- Resource *get(const std::string &idPath, const generator fun, void *const data);
+ Resource *get(const std::string &idPath, const generator fun,
+ const void *const data);
Resource *getFromCache(const std::string &idPath);
@@ -255,7 +256,7 @@ class ResourceManager
*/
SDL_Surface *loadSDLSurface(const std::string &filename) const;
- void scheduleDelete(SDL_Surface* surface);
+ void scheduleDelete(SDL_Surface *const surface);
void clearScheduled();