aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/titanic/gfx/edit_control.cpp12
-rw-r--r--engines/titanic/gfx/edit_control.h1
2 files changed, 13 insertions, 0 deletions
diff --git a/engines/titanic/gfx/edit_control.cpp b/engines/titanic/gfx/edit_control.cpp
index 9cf3a9fbd4..33707f93f6 100644
--- a/engines/titanic/gfx/edit_control.cpp
+++ b/engines/titanic/gfx/edit_control.cpp
@@ -26,6 +26,7 @@ namespace Titanic {
BEGIN_MESSAGE_MAP(CEditControl, CGameObject)
ON_MESSAGE(EditControlMsg)
+ ON_MESSAGE(MouseWheelMsg)
END_MESSAGE_MAP()
CEditControl::CEditControl() : CGameObject(), _showCursor(false), _fontNumber(0), _fieldD4(2),
@@ -220,4 +221,15 @@ bool CEditControl::EditControlMsg(CEditControlMsg *msg) {
return true;
}
+bool CEditControl::MouseWheelMsg(CMouseWheelMsg *msg) {
+ if (_name != "MissiveOMat Welcome")
+ return false;
+
+ if (msg->_wheelUp)
+ scrollTextUp();
+ else
+ scrollTextDown();
+ return true;
+}
+
} // End of namespace Titanic
diff --git a/engines/titanic/gfx/edit_control.h b/engines/titanic/gfx/edit_control.h
index 141386009b..5ed91c9e84 100644
--- a/engines/titanic/gfx/edit_control.h
+++ b/engines/titanic/gfx/edit_control.h
@@ -30,6 +30,7 @@ namespace Titanic {
class CEditControl : public CGameObject {
DECLARE_MESSAGE_MAP;
bool EditControlMsg(CEditControlMsg *msg);
+ bool MouseWheelMsg(CMouseWheelMsg *msg);
protected:
bool _showCursor;
int _editLeft;