From 5cbd0d2cb7086fda592c00dbc3b07d06af95f080 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 30 Aug 2012 22:53:27 +0300 Subject: Add const to more classes. --- src/gui/widgets/textfield.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/gui/widgets/textfield.h') diff --git a/src/gui/widgets/textfield.h b/src/gui/widgets/textfield.h index fef606526..12a101b0e 100644 --- a/src/gui/widgets/textfield.h +++ b/src/gui/widgets/textfield.h @@ -41,9 +41,11 @@ class TextField : public gcn::TextField /** * Constructor, initializes the text field with the given string. */ - TextField(const std::string &text = "", bool loseFocusOnTab = true, - gcn::ActionListener* listener = nullptr, - std::string eventId = "", bool sendAlwaysEvents = false); + TextField(const std::string &text = "", + const bool loseFocusOnTab = true, + gcn::ActionListener *const listener = nullptr, + std::string eventId = "", + const bool sendAlwaysEvents = false); ~TextField(); @@ -65,7 +67,7 @@ class TextField : public gcn::TextField /** * Determine whether the field should be numeric or not */ - void setNumeric(bool numeric); + void setNumeric(const bool numeric); /** * Set the range on the field if it is numeric @@ -107,7 +109,7 @@ class TextField : public gcn::TextField private: void handlePaste(); - void handleCopy(); + void handleCopy() const; static int instances; static float mAlpha; -- cgit v1.2.3-70-g09d2