aboutsummaryrefslogtreecommitdiff
path: root/engines/zvision/video
diff options
context:
space:
mode:
authorFilippos Karapetis2014-12-29 12:34:55 +0200
committerFilippos Karapetis2014-12-29 12:34:55 +0200
commitf4d5b150f1e4b786f2f6f79a1acd3315da9a8699 (patch)
treee1cadcc9561ed34e7462239bc5a2c82fd342cb89 /engines/zvision/video
parent83dd389d255ae63affc3600742d564a8d2cb914c (diff)
downloadscummvm-rg350-f4d5b150f1e4b786f2f6f79a1acd3315da9a8699.tar.gz
scummvm-rg350-f4d5b150f1e4b786f2f6f79a1acd3315da9a8699.tar.bz2
scummvm-rg350-f4d5b150f1e4b786f2f6f79a1acd3315da9a8699.zip
ZVISION: Show system messages when subtitles are disabled
Thanks to Marisa-Chan for spotting this
Diffstat (limited to 'engines/zvision/video')
-rw-r--r--engines/zvision/video/video.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/zvision/video/video.cpp b/engines/zvision/video/video.cpp
index e67e6570c5..0913b28818 100644
--- a/engines/zvision/video/video.cpp
+++ b/engines/zvision/video/video.cpp
@@ -29,6 +29,7 @@
#include "zvision/zvision.h"
#include "zvision/core/clock.h"
#include "zvision/graphics/render_manager.h"
+#include "zvision/scripting//script_manager.h"
#include "zvision/text/subtitles.h"
#include "zvision/video/rlf_decoder.h"
#include "zvision/video/zork_avi_decoder.h"
@@ -75,6 +76,7 @@ void ZVision::playVideo(Video::VideoDecoder &vid, const Common::Rect &destRect,
uint16 y = _workingWindow.top + dst.top;
uint16 finalWidth = dst.width() < _workingWindow.width() ? dst.width() : _workingWindow.width();
uint16 finalHeight = dst.height() < _workingWindow.height() ? dst.height() : _workingWindow.height();
+ bool showSubs = (_scriptManager->getStateValue(StateKey_Subtitles) == 1);
_clock.stop();
vid.start();
@@ -106,7 +108,7 @@ void ZVision::playVideo(Video::VideoDecoder &vid, const Common::Rect &destRect,
if (vid.needsUpdate()) {
const Graphics::Surface *frame = vid.decodeNextFrame();
- if (sub)
+ if (sub && showSubs)
sub->process(vid.getCurFrame());
if (frame) {