aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic/pet_control/pet_remote_glyphs.cpp
diff options
context:
space:
mode:
authorPaul Gilbert2017-03-29 21:49:22 -0400
committerPaul Gilbert2017-03-29 21:49:22 -0400
commit3b08987ad298dd4258df44de98fddc620d8a045f (patch)
tree578ced05ad3c43fcdc5d06c0c1d5daf7c3492c34 /engines/titanic/pet_control/pet_remote_glyphs.cpp
parent7492d620b7f619f736b73281dd42411bc55b0752 (diff)
downloadscummvm-rg350-3b08987ad298dd4258df44de98fddc620d8a045f.tar.gz
scummvm-rg350-3b08987ad298dd4258df44de98fddc620d8a045f.tar.bz2
scummvm-rg350-3b08987ad298dd4258df44de98fddc620d8a045f.zip
TITANIC: Add remote icon for skipping nav puzzle
Diffstat (limited to 'engines/titanic/pet_control/pet_remote_glyphs.cpp')
-rw-r--r--engines/titanic/pet_control/pet_remote_glyphs.cpp37
1 files changed, 37 insertions, 0 deletions
diff --git a/engines/titanic/pet_control/pet_remote_glyphs.cpp b/engines/titanic/pet_control/pet_remote_glyphs.cpp
index 7f52ca7ee9..e9b2094dc8 100644
--- a/engines/titanic/pet_control/pet_remote_glyphs.cpp
+++ b/engines/titanic/pet_control/pet_remote_glyphs.cpp
@@ -618,4 +618,41 @@ CGotoRestaurantGlyph::CGotoRestaurantGlyph() : CRemoteGotoGlyph("3Pet1stClassRes
g_vm->_strings[GO_TO_1ST_CLASS_RESTAURANT], 1) {
}
+/*------------------------------------------------------------------------*/
+
+bool CSkipNavigationGlyph::setup(CPetControl *petControl, CPetGlyphs *owner) {
+ CPetRemoteGlyph::setup(petControl, owner);
+ setDefaults("3PetTV", petControl);
+ if (owner) {
+ _button = getElement(7);
+ }
+
+ return true;
+}
+
+void CSkipNavigationGlyph::draw2(CScreenManager *screenManager) {
+ _button->draw(screenManager);
+}
+
+bool CSkipNavigationGlyph::MouseButtonDownMsg(const Point &pt) {
+ if (_button && _button->MouseButtonDownMsg(pt))
+ return true;
+
+ return false;
+}
+
+bool CSkipNavigationGlyph::MouseButtonUpMsg(const Point &pt) {
+ if (_button && _button->MouseButtonUpMsg(pt)) {
+ CActMsg actMsg("SetDestin");
+ actMsg.execute("CaptainsWheel");
+ return true;
+ }
+
+ return false;
+}
+
+void CSkipNavigationGlyph::getTooltip(CTextControl *text) {
+ text->setText(SKIP_NAVIGATION);
+}
+
} // End of namespace Titanic