aboutsummaryrefslogtreecommitdiff
path: root/engines/sludge/builtin.cpp
diff options
context:
space:
mode:
authorSimei Yin2018-04-27 14:15:09 +0200
committerSimei Yin2018-04-27 19:48:29 +0200
commit5ced49576924c18dd3d04c08f4e1822f21c52894 (patch)
tree8e171f2a7715c716cf6b8b0751401581fde07b95 /engines/sludge/builtin.cpp
parent4ce71f39225b7bc229f0048cf3bcdf5320dc9a84 (diff)
downloadscummvm-rg350-5ced49576924c18dd3d04c08f4e1822f21c52894.tar.gz
scummvm-rg350-5ced49576924c18dd3d04c08f4e1822f21c52894.tar.bz2
scummvm-rg350-5ced49576924c18dd3d04c08f4e1822f21c52894.zip
SLUDGE: Move global variable thumbnailWidth/Height to GraphicsManager
Diffstat (limited to 'engines/sludge/builtin.cpp')
-rw-r--r--engines/sludge/builtin.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/engines/sludge/builtin.cpp b/engines/sludge/builtin.cpp
index 8195fc53f9..909118a2dd 100644
--- a/engines/sludge/builtin.cpp
+++ b/engines/sludge/builtin.cpp
@@ -58,7 +58,7 @@ int speechMode = 0;
Variable *launchResult = NULL;
-extern int lastFramesPerSecond, thumbWidth, thumbHeight;
+extern int lastFramesPerSecond;
extern bool allowAnyFilename;
extern VariableStack *noStack;
extern StatusStuff *nowStatus;
@@ -2460,13 +2460,14 @@ builtIn(showThumbnail) {
builtIn(setThumbnailSize) {
UNUSEDALL
+ int thumbHeight, thumbWidth;
if (!getValueType(thumbHeight, SVT_INT, fun->stack->thisVar))
return BR_ERROR;
trimStack(fun->stack);
if (!getValueType(thumbWidth, SVT_INT, fun->stack->thisVar))
return BR_ERROR;
trimStack(fun->stack);
- if (!g_sludge->_gfxMan->checkSizeValide(thumbWidth, thumbHeight)) {
+ if (!g_sludge->_gfxMan->setThumbnailSize(thumbWidth, thumbHeight)) {
Common::String buff = Common::String::format("%i x %i", thumbWidth, thumbWidth);
fatal("Invalid thumbnail size", buff);
return BR_ERROR;