diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-08-30 02:10:59 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-08-30 02:10:59 +0300 |
commit | 46f0755975033f37eaae9db73c0e2b6499c2a923 (patch) | |
tree | 5c13c361ce4a4e4fd0e07fca1953c54637965666 /src/gui/widgets/itemcontainer.h | |
parent | 1feb7f7edc5f8f383e594b256ef4cab0fae75b99 (diff) | |
download | manaverse-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.gz manaverse-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.bz2 manaverse-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.xz manaverse-46f0755975033f37eaae9db73c0e2b6499c2a923.zip |
Add const to more classes.
Diffstat (limited to 'src/gui/widgets/itemcontainer.h')
-rw-r--r-- | src/gui/widgets/itemcontainer.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/gui/widgets/itemcontainer.h b/src/gui/widgets/itemcontainer.h index 0ad95fd1b..f39af8d7e 100644 --- a/src/gui/widgets/itemcontainer.h +++ b/src/gui/widgets/itemcontainer.h @@ -60,7 +60,8 @@ class ItemContainer : public gcn::Widget, * @param gridRows Amount of rows in grid. * @param offset Index offset */ - ItemContainer(Inventory *inventory, bool forceQuantity = false); + ItemContainer(Inventory *const inventory, + const bool forceQuantity = false); /** * Destructor. @@ -117,9 +118,9 @@ class ItemContainer : public gcn::Widget, void removeSelectionListener(gcn::SelectionListener *listener) { mSelectionListeners.remove(listener); } - void setFilter (int tag); + void setFilter(const int tag); - void setSortType (int sortType); + void setSortType(const int sortType); void setName(std::string str) { mName = str; } @@ -157,12 +158,12 @@ class ItemContainer : public gcn::Widget, * * @param direction The move direction of the highlighter. */ - void moveHighlight(Direction direction); + void moveHighlight(const Direction direction); /** * Sets the currently selected item. */ - void setSelectedIndex(int index); + void setSelectedIndex(const int index); /** * Determine and set the height of the container. @@ -181,7 +182,7 @@ class ItemContainer : public gcn::Widget, * @param y The Y coordinate position. * @return The slot index on success, -1 on failure. */ - int getSlotIndex(int x, int y) const; + int getSlotIndex(const int x, const int y) const; Inventory *mInventory; |