From 73c25028b8dc33112ac058bd5177b66b7c692520 Mon Sep 17 00:00:00 2001 From: djsrv Date: Fri, 24 Jul 2020 00:10:03 -0400 Subject: [PATCH] DIRECTOR: LINGO: Add custom asString for window --- engines/director/lingo/lingo-object.cpp | 4 ++++ engines/director/stage.h | 1 + 2 files changed, 5 insertions(+) diff --git a/engines/director/lingo/lingo-object.cpp b/engines/director/lingo/lingo-object.cpp index d97296c6d72..64fa5dd0fd9 100644 --- a/engines/director/lingo/lingo-object.cpp +++ b/engines/director/lingo/lingo-object.cpp @@ -319,6 +319,10 @@ void LM::m_respondsTo(int nargs) { // Window +Common::String Stage::asString() { + return "window \"" + getName() + "\""; +} + bool Stage::hasProp(const Common::String &propName) { Common::String fieldName = Common::String::format("%d%s", kTheWindow, propName.c_str()); return g_lingo->_theEntityFields.contains(fieldName); diff --git a/engines/director/stage.h b/engines/director/stage.h index 5791c8fe0ad..1b8be74c8e7 100644 --- a/engines/director/stage.h +++ b/engines/director/stage.h @@ -144,6 +144,7 @@ class Stage : public Graphics::MacWindow, public Object { void loadMac(const Common::String movie); // lingo/lingo-object.cpp + virtual Common::String asString(); virtual bool hasProp(const Common::String &propName); virtual Datum getProp(const Common::String &propName); virtual bool setProp(const Common::String &propName, const Datum &value);