From 8fdaa55cfc951459b0ee079839cdf40e88baa2af Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 20 Jul 2011 23:03:30 +0300 Subject: Small optimisations. --- src/gui/outfitwindow.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'src/gui') diff --git a/src/gui/outfitwindow.h b/src/gui/outfitwindow.h index 2d2f6271b..60634dbdd 100644 --- a/src/gui/outfitwindow.h +++ b/src/gui/outfitwindow.h @@ -28,6 +28,12 @@ #include #include +#ifdef __GNUC__ +#define A_PURE __attribute__ ((pure)) +#else +#define A_PURE +#endif + #define OUTFITS_COUNT 100 #define OUTFIT_ITEM_COUNT 12 @@ -82,9 +88,9 @@ class OutfitWindow : public Window, gcn::ActionListener void unequipNotInOutfit(int outfit); - int keyToNumber(SDLKey key) const; + int keyToNumber(SDLKey key) const A_PURE; - SDLKey numberToKey(int number) const; + SDLKey numberToKey(int number) const A_PURE; void next(); @@ -100,7 +106,7 @@ class OutfitWindow : public Window, gcn::ActionListener void showCurrentOutfit(); - std::string keyName(int number); + std::string keyName(int number) A_PURE; private: Button *mPreviousButton; -- cgit v1.2.3-70-g09d2