aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine
diff options
context:
space:
mode:
authorFilippos Karapetis2009-11-04 12:19:05 +0000
committerFilippos Karapetis2009-11-04 12:19:05 +0000
commit12e3375f3b47e6e626d8457257fd2036ed835ab1 (patch)
treed750bc29a6db7bc4443e7d60e2c23509bf95119f /engines/sci/engine
parenteffdfcd4b8c92475d41a15cefbfd711724280924 (diff)
downloadscummvm-rg350-12e3375f3b47e6e626d8457257fd2036ed835ab1.tar.gz
scummvm-rg350-12e3375f3b47e6e626d8457257fd2036ed835ab1.tar.bz2
scummvm-rg350-12e3375f3b47e6e626d8457257fd2036ed835ab1.zip
Removed the reference to SciGuiCursor from EngineState
svn-id: r45660
Diffstat (limited to 'engines/sci/engine')
-rw-r--r--engines/sci/engine/kevent.cpp2
-rw-r--r--engines/sci/engine/kgraphics.cpp2
-rw-r--r--engines/sci/engine/savegame.cpp2
-rw-r--r--engines/sci/engine/state.cpp4
-rw-r--r--engines/sci/engine/state.h3
5 files changed, 6 insertions, 7 deletions
diff --git a/engines/sci/engine/kevent.cpp b/engines/sci/engine/kevent.cpp
index f7f01d9a6e..34fba22de1 100644
--- a/engines/sci/engine/kevent.cpp
+++ b/engines/sci/engine/kevent.cpp
@@ -43,7 +43,7 @@ reg_t kGetEvent(EngineState *s, int argc, reg_t *argv) {
int oldx, oldy;
int modifier_mask = getSciVersion() <= SCI_VERSION_01 ? SCI_EVM_ALL : SCI_EVM_NO_FOOLOCK;
SegManager *segMan = s->_segMan;
- const Common::Point mousePos = s->_cursor->getPosition();
+ const Common::Point mousePos = s->_gui->getCursorPos();
// If there's a simkey pending, and the game wants a keyboard event, use the
// simkey instead of a normal event
diff --git a/engines/sci/engine/kgraphics.cpp b/engines/sci/engine/kgraphics.cpp
index 24a0737aa8..f26e014b2d 100644
--- a/engines/sci/engine/kgraphics.cpp
+++ b/engines/sci/engine/kgraphics.cpp
@@ -128,7 +128,7 @@ static reg_t kSetCursorSci11(EngineState *s, int argc, reg_t *argv) {
if ((right >= left) && (bottom >= top)) {
Common::Rect rect = Common::Rect(left, top, right, bottom);
- s->_cursor->setMoveZone(rect);
+ s->_gui->setCursorZone(rect);
} else {
warning("kSetCursor: Ignoring invalid mouse zone (%i, %i)-(%i, %i)", left, top, right, bottom);
}
diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp
index fd8cb6e142..406c450107 100644
--- a/engines/sci/engine/savegame.cpp
+++ b/engines/sci/engine/savegame.cpp
@@ -737,7 +737,7 @@ EngineState *gamestate_restore(EngineState *s, Common::SeekableReadStream *fh) {
}
// FIXME: Do in-place loading at some point, instead of creating a new EngineState instance from scratch.
- retval = new EngineState(s->resMan, s->_kernel, s->_voc, s->_gui, s->_cursor, s->_audio);
+ retval = new EngineState(s->resMan, s->_kernel, s->_voc, s->_gui, s->_audio);
// Copy some old data
retval->gfx_state = s->gfx_state;
diff --git a/engines/sci/engine/state.cpp b/engines/sci/engine/state.cpp
index 5925698e49..06cace2b99 100644
--- a/engines/sci/engine/state.cpp
+++ b/engines/sci/engine/state.cpp
@@ -32,8 +32,8 @@
namespace Sci {
-EngineState::EngineState(ResourceManager *res, Kernel *kernel, Vocabulary *voc, SciGui *gui, SciGuiCursor *cursor, AudioPlayer *audio)
-: resMan(res), _kernel(kernel), _voc(voc), _gui(gui), _cursor(cursor), _audio(audio), _dirseeker(this) {
+EngineState::EngineState(ResourceManager *res, Kernel *kernel, Vocabulary *voc, SciGui *gui, AudioPlayer *audio)
+: resMan(res), _kernel(kernel), _voc(voc), _gui(gui), _audio(audio), _dirseeker(this) {
gfx_state = 0;
diff --git a/engines/sci/engine/state.h b/engines/sci/engine/state.h
index 9e517adf4b..21ccb2a07a 100644
--- a/engines/sci/engine/state.h
+++ b/engines/sci/engine/state.h
@@ -116,7 +116,7 @@ public:
struct EngineState : public Common::Serializable {
public:
- EngineState(ResourceManager *res, Kernel *kernel, Vocabulary *voc, SciGui *gui, SciGuiCursor *cursor, AudioPlayer *audio);
+ EngineState(ResourceManager *res, Kernel *kernel, Vocabulary *voc, SciGui *gui, AudioPlayer *audio);
virtual ~EngineState();
virtual void saveLoadWithSerializer(Common::Serializer &ser);
@@ -132,7 +132,6 @@ public:
/* Non-VM information */
SciGui *_gui; /* Currently active Gui */
- SciGuiCursor *_cursor; /* Cursor functions */
GfxState *gfx_state; /**< Graphics state and driver */