diff options
author | Eugene Sandulenko | 2017-08-01 00:30:27 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2017-08-01 10:42:22 +0200 |
commit | 48f07f027655c231117142d012c8d7fdc6808cbd (patch) | |
tree | e03c778e7b73cb5c23f12562fd4c44a63b91fde4 /graphics/macgui | |
parent | 63e9f41f4e1a10574e999cac63f1b1c5351037d3 (diff) | |
download | scummvm-rg350-48f07f027655c231117142d012c8d7fdc6808cbd.tar.gz scummvm-rg350-48f07f027655c231117142d012c8d7fdc6808cbd.tar.bz2 scummvm-rg350-48f07f027655c231117142d012c8d7fdc6808cbd.zip |
GRAPHICS: MACGUI: Render MacTextWindow internally
Diffstat (limited to 'graphics/macgui')
-rw-r--r-- | graphics/macgui/mactextwindow.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/graphics/macgui/mactextwindow.cpp b/graphics/macgui/mactextwindow.cpp index 862bce2b76..b02fe56e08 100644 --- a/graphics/macgui/mactextwindow.cpp +++ b/graphics/macgui/mactextwindow.cpp @@ -110,13 +110,16 @@ bool MacTextWindow::draw(ManagedSurface *g, bool forceRedraw) { if (!_borderIsDirty && !_contentIsDirty && !_cursorDirty && !forceRedraw) return false; - if (_borderIsDirty || forceRedraw) + if (_borderIsDirty || forceRedraw) { drawBorder(); + _composeSurface.clear(kColorWhite); + } + _contentIsDirty = false; // Compose - _composeSurface.blitFrom(_surface, Common::Rect(0, 0, _surface.w - 2, _surface.h - 2), Common::Point(2, 2)); + _mactext->draw(&_composeSurface, 0, 0, _surface.w - 2, _surface.h - 2, kConWOverlap - 2, kConWOverlap - 2); if (_cursorState) _composeSurface.blitFrom(*_cursorSurface, *_cursorRect, Common::Point(_cursorX + kConWOverlap, _cursorY + kConHOverlap)); @@ -206,7 +209,7 @@ void MacTextWindow::updateCursorPos() { if (_scrollPos) _cursorY = _mactext->getTextHeight() - kCursorHeight * 2; else - _cursorY = _mactext->getTextHeight() - kCursorHeight; + _cursorY = _mactext->getTextHeight() - kCursorHeight - 2; _cursorDirty = true; } |