Skip to content

Commit

Permalink
CLEANUP: Remove useless const-qualifiers on value return types.
Browse files Browse the repository at this point in the history
  • Loading branch information
berenm authored and DrMcCoy committed Aug 17, 2013
1 parent 7b3d238 commit 506ea11
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 16 deletions.
8 changes: 4 additions & 4 deletions src/aurora/2dafile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,31 +64,31 @@ const Common::UString &TwoDARow::getString(const Common::UString &column) const
return cell;
}

const int32 TwoDARow::getInt(uint32 column) const {
int32 TwoDARow::getInt(uint32 column) const {
const Common::UString &cell = getCell(column);
if (cell.empty() || (cell == "****"))
return _parent->_defaultInt;

return _parent->parseInt(cell);
}

const int32 TwoDARow::getInt(const Common::UString &column) const {
int32 TwoDARow::getInt(const Common::UString &column) const {
const Common::UString &cell = getCell(_parent->headerToColumn(column));
if (cell.empty() || (cell == "****"))
return _parent->_defaultInt;

return _parent->parseInt(cell);
}

const float TwoDARow::getFloat(uint32 column) const {
float TwoDARow::getFloat(uint32 column) const {
const Common::UString &cell = getCell(column);
if (cell.empty() || (cell == "****"))
return _parent->_defaultFloat;

return _parent->parseFloat(cell);
}

const float TwoDARow::getFloat(const Common::UString &column) const {
float TwoDARow::getFloat(const Common::UString &column) const {
const Common::UString &cell = getCell(_parent->headerToColumn(column));
if (cell.empty() || (cell == "****"))
return _parent->_defaultFloat;
Expand Down
8 changes: 4 additions & 4 deletions src/aurora/2dafile.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,14 @@ class TwoDARow {
const Common::UString &getString(const Common::UString &column) const;

/** Return the contents of a cell as an int. */
const int32 getInt(uint32 column) const;
int32 getInt(uint32 column) const;
/** Return the contents of a cell as an int. */
const int32 getInt(const Common::UString &column) const;
int32 getInt(const Common::UString &column) const;

/** Return the contents of a cell as a float. */
const float getFloat(uint32 column) const;
float getFloat(uint32 column) const;
/** Return the contents of a cell as a float. */
const float getFloat(const Common::UString &column) const;
float getFloat(const Common::UString &column) const;

private:
TwoDAFile *_parent; ///< The parent 2DA.
Expand Down
2 changes: 1 addition & 1 deletion src/engines/aurora/console.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ void ConsoleWindow::clearHighlight() {
updateHighlight();
}

const Common::UString ConsoleWindow::getHighlight() const {
Common::UString ConsoleWindow::getHighlight() const {
if ((_highlightLength == 0) || (_highlightY >= kConsoleLines))
return "";

Expand Down
2 changes: 1 addition & 1 deletion src/engines/aurora/console.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ class ConsoleWindow : public Graphics::GUIFrontElement, public Events::Notifyabl
void highlightWord(int x, int y);
void highlightLine(int x, int y);

const Common::UString getHighlight() const;
Common::UString getHighlight() const;


// Scrolling
Expand Down
2 changes: 1 addition & 1 deletion src/engines/nwn/waypoint.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ bool Waypoint::hasMapNote() const {
return _hasMapNote;
}

const Common::UString Waypoint::getMapNote() const {
Common::UString Waypoint::getMapNote() const {
return _mapNote;
}

Expand Down
2 changes: 1 addition & 1 deletion src/engines/nwn/waypoint.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class Waypoint : public Object {
/** Does this waypoint have a map note? */
bool hasMapNote() const;
/** Return the waypoint's map note text. */
const Common::UString getMapNote() const;
Common::UString getMapNote() const;

/** Enable/Disable the waypoint's map note. */
void enableMapNote(bool enabled);
Expand Down
4 changes: 2 additions & 2 deletions src/graphics/aurora/texture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,11 @@ TextureID Texture::getID() const {
return _textureID;
}

const uint32 Texture::getWidth() const {
uint32 Texture::getWidth() const {
return _width;
}

const uint32 Texture::getHeight() const {
uint32 Texture::getHeight() const {
return _height;
}

Expand Down
4 changes: 2 additions & 2 deletions src/graphics/aurora/texture.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ class Texture : public Graphics::Texture {
Texture(ImageDecoder *image, const TXI *txi = 0);
~Texture();

const uint32 getWidth() const;
const uint32 getHeight() const;
uint32 getWidth() const;
uint32 getHeight() const;

bool hasAlpha() const;

Expand Down

0 comments on commit 506ea11

Please sign in to comment.