diff options
| -rw-r--r-- | engines/director/frame.cpp | 1 | ||||
| -rw-r--r-- | graphics/macgui/mactext.cpp | 5 | ||||
| -rw-r--r-- | graphics/macgui/mactext.h | 2 | 
3 files changed, 6 insertions, 2 deletions
diff --git a/engines/director/frame.cpp b/engines/director/frame.cpp index 3b3c1ff978..49c755ce23 100644 --- a/engines/director/frame.cpp +++ b/engines/director/frame.cpp @@ -847,7 +847,6 @@ void Frame::renderText(Graphics::ManagedSurface &surface, uint16 spriteId, Commo  	}  	Graphics::MacFont *macFont = new Graphics::MacFont(textCast->fontId, textCast->fontSize, textCast->textSlant); -	// TODO: MacText must destroy me  	debugC(3, kDebugText, "renderText: x: %d y: %d w: %d h: %d font: '%s'", x, y, width, height, _vm->_wm->_fontMan->getFontName(*macFont)); diff --git a/graphics/macgui/mactext.cpp b/graphics/macgui/mactext.cpp index 9dcb380833..62c4e8efa4 100644 --- a/graphics/macgui/mactext.cpp +++ b/graphics/macgui/mactext.cpp @@ -37,6 +37,11 @@ const Font *MacFontRun::getFont() {  	return font;  } + +MacText::~MacText(){ +	delete _macFont; +} +  MacText::MacText(Common::String s, MacWindowManager *wm, const MacFont *macFont, int fgcolor, int bgcolor, int maxWidth, TextAlign textAlignment) {  	_str = s;  	_wm = wm; diff --git a/graphics/macgui/mactext.h b/graphics/macgui/mactext.h index c9d24a006d..25f6002707 100644 --- a/graphics/macgui/mactext.h +++ b/graphics/macgui/mactext.h @@ -90,7 +90,7 @@ class MacText {  public:  	MacText(Common::String s, MacWindowManager *wm, const MacFont *font, int fgcolor, int bgcolor,  				int maxWidth = -1, TextAlign textAlignment = kTextAlignLeft); - +	~MacText();  	void setInterLinear(int interLinear);  	void draw(ManagedSurface *g, int x, int y, int w, int h, int xoff, int yoff);  | 
