Fix crash when using textarea without form

--HG--
branch : develop
hg/feature/light_cycle
Nimetu 10 years ago
parent 176c3d8a4a
commit 48b346fed8

@ -1681,11 +1681,9 @@ namespace NLGUI
break;
case HTML_TEXTAREA:
{
// Add the editbox
// nlinfo("textarea temp '%s'", _TextAreaTemplate.c_str());
// nlinfo("textarea name '%s'", _TextAreaName.c_str());
// nlinfo("textarea %d %d", _TextAreaRow, _TextAreaCols);
// nlinfo("textarea content '%s'", _TextAreaContent.toUtf8().c_str());
_TextArea = false;
if (!(_Forms.empty()))
{
CInterfaceGroup *textArea = addTextArea (_TextAreaTemplate, _TextAreaName.c_str (), _TextAreaRow, _TextAreaCols, true, _TextAreaContent, _TextAreaMaxLength);
if (textArea)
{
@ -1695,7 +1693,7 @@ namespace NLGUI
entry.TextArea = textArea;
_Forms.back().Entries.push_back (entry);
}
_TextArea = false;
}
}
break;
case HTML_TITLE:

Loading…
Cancel
Save