From b8835bb8f60ebaaedbf474624ffceb1b181c3036 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 23 Dec 2015 01:49:01 +0300 Subject: Add const attribute to resources. --- src/resources/atlas/atlasmanager.h | 2 +- src/resources/beinginfo.h | 2 +- src/resources/db/emotedb.h | 2 +- src/resources/dye/dyepalette.h | 3 ++- src/resources/sdlscreenshothelper.h | 2 +- 5 files changed, 6 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/resources/atlas/atlasmanager.h b/src/resources/atlas/atlasmanager.h index b30981be6..28476dc2e 100644 --- a/src/resources/atlas/atlasmanager.h +++ b/src/resources/atlas/atlasmanager.h @@ -38,7 +38,7 @@ struct TextureAtlas; class AtlasManager final { public: - AtlasManager(); + AtlasManager() A_CONST; A_DELETE_COPY(AtlasManager) diff --git a/src/resources/beinginfo.h b/src/resources/beinginfo.h index 139c5e5c7..30bd01bd5 100644 --- a/src/resources/beinginfo.h +++ b/src/resources/beinginfo.h @@ -325,7 +325,7 @@ class BeingInfo final void addMenu(const std::string &name, const std::string &command); - const std::vector &getMenu() const; + const std::vector &getMenu() const A_CONST; static void init(); diff --git a/src/resources/db/emotedb.h b/src/resources/db/emotedb.h index 9372aa670..ec2c78dbb 100644 --- a/src/resources/db/emotedb.h +++ b/src/resources/db/emotedb.h @@ -54,7 +54,7 @@ namespace EmoteDB const EmoteSprite *getSprite(const int id, const bool allowNull = false) A_WARN_UNUSED; - const int &getLast() A_WARN_UNUSED; + const int &getLast() A_CONST A_WARN_UNUSED; int getIdByIndex(const int index); diff --git a/src/resources/dye/dyepalette.h b/src/resources/dye/dyepalette.h index 33d16fa50..1269d1511 100644 --- a/src/resources/dye/dyepalette.h +++ b/src/resources/dye/dyepalette.h @@ -79,7 +79,8 @@ class DyePalette final void replaceAOGLColor(uint32_t *restrict pixels, const int bufSize) const; - static unsigned int hexDecode(const signed char c) A_WARN_UNUSED; + static unsigned int hexDecode(const signed char c) + A_CONST A_WARN_UNUSED; private: std::vector mColors; diff --git a/src/resources/sdlscreenshothelper.h b/src/resources/sdlscreenshothelper.h index ff0989cd6..285fd400e 100644 --- a/src/resources/sdlscreenshothelper.h +++ b/src/resources/sdlscreenshothelper.h @@ -36,7 +36,7 @@ class SdlScreenshotHelper final : public ScreenshotHelper ~SdlScreenshotHelper(); - void prepare() override final; + void prepare() override final A_CONST; SDL_Surface *getScreenshot() override final; }; -- cgit v1.2.3-60-g2f50