diff options
author | Eugene Sandulenko | 2014-04-20 22:52:31 +0300 |
---|---|---|
committer | Eugene Sandulenko | 2014-04-20 23:03:44 +0300 |
commit | 3fe9d4b24ea560b34f67cac41e37dfe8900a9d43 (patch) | |
tree | 5c8bdaf58867ede1f2db470eedc56469758a244c /engines/fullpipe | |
parent | f655718b5559682c279941cd41ea612670190c5b (diff) | |
download | scummvm-rg350-3fe9d4b24ea560b34f67cac41e37dfe8900a9d43.tar.gz scummvm-rg350-3fe9d4b24ea560b34f67cac41e37dfe8900a9d43.tar.bz2 scummvm-rg350-3fe9d4b24ea560b34f67cac41e37dfe8900a9d43.zip |
FULLPIPE: Implement ModalQuery::update()
Diffstat (limited to 'engines/fullpipe')
-rw-r--r-- | engines/fullpipe/modal.cpp | 17 | ||||
-rw-r--r-- | engines/fullpipe/modal.h | 6 |
2 files changed, 18 insertions, 5 deletions
diff --git a/engines/fullpipe/modal.cpp b/engines/fullpipe/modal.cpp index dd5d507299..1569ee981c 100644 --- a/engines/fullpipe/modal.cpp +++ b/engines/fullpipe/modal.cpp @@ -920,7 +920,7 @@ bool ModalMainMenu::init(int counterdiff) { g_fp->_modalObject = mq; mq->_parentObj = this; - mq->create(_scene, &_scene->_picObjList, PIC_MEX_BGR); + mq->create(_scene, (PictureObject *)_scene->_picObjList[0], PIC_MEX_BGR); _hoverAreaId = 0; @@ -1335,7 +1335,7 @@ ModalQuery::~ModalQuery() { _okBtn->_flags &= 0xFFFB; } -bool ModalQuery::create(Scene *sc, PtrList *picObjList, int id) { +bool ModalQuery::create(Scene *sc, PictureObject *picObjList, int id) { if (id == PIC_MEX_BGR) { _bg = sc->getPictureObjectById(PIC_MEX_BGR, 0); @@ -1377,6 +1377,19 @@ bool ModalQuery::create(Scene *sc, PtrList *picObjList, int id) { return true; } +void ModalQuery::update() { + if (_picObjList) + _picObjList->draw(); + + _bg->draw(); + + if (_okBtn->_flags & 4) + _okBtn->draw(); + + if (_cancelBtn->_flags & 4) + _cancelBtn->draw(); +} + void ModalSaveGame::setScene(Scene *sc) { warning("STUB: ModalSaveGame::setScene()"); } diff --git a/engines/fullpipe/modal.h b/engines/fullpipe/modal.h index d7b5fc2455..4b16c305aa 100644 --- a/engines/fullpipe/modal.h +++ b/engines/fullpipe/modal.h @@ -221,15 +221,15 @@ public: virtual bool pollEvent() { return true; } virtual bool handleMessage(ExCommand *message) { return false; } virtual bool init(int counterdiff) { return true; } - virtual void update() {} + virtual void update(); virtual void saveload() {} - bool create(Scene *sc, PtrList *picObjList, int picId); + bool create(Scene *sc, PictureObject *picObjList, int picId); int getQueryResult() { return _queryResult; } private: - PtrList *_picObjList; + PictureObject *_picObjList; PictureObject *_bg; PictureObject *_okBtn; PictureObject *_cancelBtn; |