diff options
author | Gregory Montoir | 2007-01-27 02:26:37 +0000 |
---|---|---|
committer | Gregory Montoir | 2007-01-27 02:26:37 +0000 |
commit | 2b61c0d6c1efba14b23655905751981e9b19e365 (patch) | |
tree | c3964a11338fc21e7e9542ced5b860fa167c3daf /engines/scumm/smush/smush_font.cpp | |
parent | 843b30403163b67ec277f086f3ead587bd50e266 (diff) | |
download | scummvm-rg350-2b61c0d6c1efba14b23655905751981e9b19e365.tar.gz scummvm-rg350-2b61c0d6c1efba14b23655905751981e9b19e365.tar.bz2 scummvm-rg350-2b61c0d6c1efba14b23655905751981e9b19e365.zip |
cleanup (made NutRenderer::loadFont protected, added call during initialisation of the renderer object)
svn-id: r25223
Diffstat (limited to 'engines/scumm/smush/smush_font.cpp')
-rw-r--r-- | engines/scumm/smush/smush_font.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/engines/scumm/smush/smush_font.cpp b/engines/scumm/smush/smush_font.cpp index 59caaeea61..de7fe9c460 100644 --- a/engines/scumm/smush/smush_font.cpp +++ b/engines/scumm/smush/smush_font.cpp @@ -29,8 +29,8 @@ namespace Scumm { -SmushFont::SmushFont(ScummEngine *vm, bool use_original_colors, bool new_colors) : - NutRenderer(vm), +SmushFont::SmushFont(ScummEngine *vm, const char *filename, bool use_original_colors, bool new_colors) : + NutRenderer(vm, filename, false), _color(-1), _new_colors(new_colors), _original(use_original_colors) { @@ -38,10 +38,6 @@ SmushFont::SmushFont(ScummEngine *vm, bool use_original_colors, bool new_colors) int SmushFont::getStringWidth(const char *str) { assert(str); - if (!_loaded) { - error("SmushFont::getStringWidth() Font is not loaded"); - return 0; - } int width = 0; while (*str) { @@ -56,10 +52,6 @@ int SmushFont::getStringWidth(const char *str) { int SmushFont::getStringHeight(const char *str) { assert(str); - if (!_loaded) { - error("SmushFont::getStringHeight() Font is not loaded"); - return 0; - } int height = 0; while (*str) { |