aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2020-01-05 11:34:17 +0100
committerEugene Sandulenko2020-01-05 11:34:17 +0100
commit5a06fcecddd0fec6336a24b8f84ca73b055f8bdd (patch)
treef663b01d27c662bd130e3acdbf4231264e8f0da2
parent3c0ee870220d90014603f3a52695b1f83865caf5 (diff)
downloadscummvm-rg350-5a06fcecddd0fec6336a24b8f84ca73b055f8bdd.tar.gz
scummvm-rg350-5a06fcecddd0fec6336a24b8f84ca73b055f8bdd.tar.bz2
scummvm-rg350-5a06fcecddd0fec6336a24b8f84ca73b055f8bdd.zip
GRAPHICS: MACGUI: Generate MacText surface for empty texts
-rw-r--r--graphics/macgui/mactext.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/graphics/macgui/mactext.cpp b/graphics/macgui/mactext.cpp
index 916219fe73..2fc9b8dd33 100644
--- a/graphics/macgui/mactext.cpp
+++ b/graphics/macgui/mactext.cpp
@@ -69,8 +69,7 @@ MacText::MacText(Common::U32String s, MacWindowManager *wm, const MacFont *macFo
_currentFormatting = _defaultFormatting;
- if (!_str.empty())
- splitString(_str);
+ splitString(_str);
recalcDims();
@@ -101,8 +100,7 @@ MacText::MacText(const Common::String &s, MacWindowManager *wm, const MacFont *m
_currentFormatting = _defaultFormatting;
- if (!_str.empty())
- splitString(_str);
+ splitString(_str);
recalcDims();
@@ -114,13 +112,11 @@ void MacText::setMaxWidth(int maxWidth) {
_textLines.clear();
- if (!_str.empty()) {
- splitString(_str);
+ splitString(_str);
- recalcDims();
+ recalcDims();
- _fullRefresh = true;
- }
+ _fullRefresh = true;
}
static const Common::U32String::value_type *readHex(uint16 *res, const Common::U32String::value_type *s, int len) {