aboutsummaryrefslogtreecommitdiff
path: root/engines/wintermute/ui
diff options
context:
space:
mode:
authorEinar Johan Trøan Sømåen2013-09-30 11:12:25 +0200
committerEinar Johan Trøan Sømåen2013-09-30 11:12:25 +0200
commit5afb297e396fa3ad40559e552008741c6cd6ba66 (patch)
treef93699e55a7373dc14f7699cd5cd219881d80216 /engines/wintermute/ui
parentf7a9e921aee9371a9defe5acaf4a685ada76fcfb (diff)
downloadscummvm-rg350-5afb297e396fa3ad40559e552008741c6cd6ba66.tar.gz
scummvm-rg350-5afb297e396fa3ad40559e552008741c6cd6ba66.tar.bz2
scummvm-rg350-5afb297e396fa3ad40559e552008741c6cd6ba66.zip
WINTERMUTE: Constify some getters in TransparentSurface, UIObject and UIWindow
Diffstat (limited to 'engines/wintermute/ui')
-rw-r--r--engines/wintermute/ui/ui_object.cpp12
-rw-r--r--engines/wintermute/ui/ui_object.h12
-rw-r--r--engines/wintermute/ui/ui_window.cpp4
-rw-r--r--engines/wintermute/ui/ui_window.h4
4 files changed, 16 insertions, 16 deletions
diff --git a/engines/wintermute/ui/ui_object.cpp b/engines/wintermute/ui/ui_object.cpp
index 224e68add7..0962d83f8b 100644
--- a/engines/wintermute/ui/ui_object.cpp
+++ b/engines/wintermute/ui/ui_object.cpp
@@ -666,11 +666,11 @@ void UIObject::setHeight(int32 height) {
_height = height;
}
-bool UIObject::isDisabled() {
+bool UIObject::isDisabled() const {
return _disable;
}
-bool UIObject::isVisible() {
+bool UIObject::isVisible() const {
return _visible;
}
@@ -682,7 +682,7 @@ void UIObject::setDisabled(bool disable) {
_disable = disable;
}
-bool UIObject::hasSharedFonts() {
+bool UIObject::hasSharedFonts() const {
return _sharedFonts;
}
@@ -690,7 +690,7 @@ void UIObject::setSharedFonts(bool shared) {
_sharedFonts = shared;
}
-bool UIObject::hasSharedImages() {
+bool UIObject::hasSharedImages() const {
return _sharedImages;
}
@@ -706,7 +706,7 @@ void UIObject::setImage(BaseSprite *image) {
_image = image;
}
-bool UIObject::canFocus() {
+bool UIObject::canFocus() const {
return _canFocus;
}
@@ -714,7 +714,7 @@ void UIObject::setFont(BaseFont *font) {
_font = font;
}
-BaseFont *UIObject::getFont() const {
+BaseFont *UIObject::getFont() {
return _font;
}
diff --git a/engines/wintermute/ui/ui_object.h b/engines/wintermute/ui/ui_object.h
index d9be29ba9a..56d22a0b18 100644
--- a/engines/wintermute/ui/ui_object.h
+++ b/engines/wintermute/ui/ui_object.h
@@ -72,19 +72,19 @@ public:
int32 getHeight() const;
void setHeight(int32 height);
void setWidth(int32 width);
- bool isDisabled();
+ bool isDisabled() const;
void setDisabled(bool disable);
- bool isVisible();
+ bool isVisible() const;
void setVisible(bool visible);
- bool hasSharedFonts();
+ bool hasSharedFonts() const;
void setSharedFonts(bool shared);
- bool hasSharedImages();
+ bool hasSharedImages() const;
void setSharedImages(bool shared);
BaseSprite *getImage() const;
void setImage(BaseSprite *image);
void setFont(BaseFont *font);
- BaseFont *getFont() const;
- bool canFocus();
+ BaseFont *getFont();
+ bool canFocus() const;
protected:
BaseScriptHolder *_listenerParamObject;
diff --git a/engines/wintermute/ui/ui_window.cpp b/engines/wintermute/ui/ui_window.cpp
index c098415367..a54f7c5da1 100644
--- a/engines/wintermute/ui/ui_window.cpp
+++ b/engines/wintermute/ui/ui_window.cpp
@@ -1442,11 +1442,11 @@ bool UIWindow::getWindowObjects(BaseArray<UIObject *> &objects, bool interactive
return STATUS_OK;
}
-bool UIWindow::getInGame() {
+bool UIWindow::getInGame() const {
return _inGame;
}
-TWindowMode UIWindow::getMode() {
+TWindowMode UIWindow::getMode() const {
return _mode;
}
diff --git a/engines/wintermute/ui/ui_window.h b/engines/wintermute/ui/ui_window.h
index 9175e3cde8..d8dae8c0d3 100644
--- a/engines/wintermute/ui/ui_window.h
+++ b/engines/wintermute/ui/ui_window.h
@@ -73,8 +73,8 @@ public:
virtual bool scCallMethod(ScScript *script, ScStack *stack, ScStack *thisStack, const char *name) override;
virtual const char *scToString();
- bool getInGame();
- TWindowMode getMode();
+ bool getInGame() const;
+ TWindowMode getMode() const;
private:
bool _pauseMusic;