diff options
author | Alyssa Milburn | 2011-02-20 13:44:19 +0100 |
---|---|---|
committer | Alyssa Milburn | 2011-02-20 13:46:13 +0100 |
commit | 0fe3ecd6d7091d347fb1c2b7c899de5ad2c35b28 (patch) | |
tree | 3190c0bd1ed7aeb11430b22b894a0ca5512452dd | |
parent | 42ec234a1f32724cc713bd045cdb96d871c7d2c0 (diff) | |
download | scummvm-rg350-0fe3ecd6d7091d347fb1c2b7c899de5ad2c35b28.tar.gz scummvm-rg350-0fe3ecd6d7091d347fb1c2b7c899de5ad2c35b28.tar.bz2 scummvm-rg350-0fe3ecd6d7091d347fb1c2b7c899de5ad2c35b28.zip |
MOHAWK: Don't display LiveText phrases too early.
-rw-r--r-- | engines/mohawk/livingbooks.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/engines/mohawk/livingbooks.cpp b/engines/mohawk/livingbooks.cpp index e4d51c3a02..20f7684521 100644 --- a/engines/mohawk/livingbooks.cpp +++ b/engines/mohawk/livingbooks.cpp @@ -3213,7 +3213,7 @@ void LBLiveTextItem::drawWord(uint word, uint yPos) { } void LBLiveTextItem::handleMouseDown(Common::Point pos) { - if (_neverEnabled || !_enabled || !_globalEnabled || _currentPhrase != 0xFFFF) + if (_neverEnabled || !_enabled || !_globalEnabled || _playing) return LBItem::handleMouseDown(pos); pos.x -= _rect.left; @@ -3245,16 +3245,13 @@ bool LBLiveTextItem::togglePlaying(bool playing, bool restart) { if (!playing) return LBItem::togglePlaying(playing, restart); if (_neverEnabled || !_enabled || !_globalEnabled) - return (_currentPhrase != 0xFFFF); + return _playing; // TODO: handle this properly _vm->_sound->stopSound(); _currentWord = 0xFFFF; - - // some LiveText items don't have any phrases! - if (_phrases.size() > 0) - _currentPhrase = 0; + _currentPhrase = 0xFFFF; return true; } @@ -3266,7 +3263,7 @@ void LBLiveTextItem::stop() { } void LBLiveTextItem::notify(uint16 data, uint16 from) { - if (_neverEnabled || !_enabled || !_globalEnabled || _currentPhrase == 0xFFFF) + if (_neverEnabled || !_enabled || !_globalEnabled || !_playing) return LBItem::notify(data, from); if (_currentWord != 0xFFFF) { |