diff --git a/source/glest_game/game/chat_manager.cpp b/source/glest_game/game/chat_manager.cpp index b337dfec..30b9901c 100644 --- a/source/glest_game/game/chat_manager.cpp +++ b/source/glest_game/game/chat_manager.cpp @@ -104,10 +104,14 @@ bool ChatManager::textInput(std::string inputText) { string textToAdd=inputText.substr (0,maxpaste); if(editEnabled && (int)text.length() < maxTextLenAllowed) { SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s Line: %d]\n",__FILE__,__FUNCTION__,__LINE__); - for(unsigned int idx = 0; idx < textToAdd.size(); ++idx) { - textCharLength.push_back(1); - } - this->text +=textToAdd; +// for(unsigned int idx = 0; idx < textToAdd.size(); ++idx) { +// textCharLength.push_back(1); +// } +// this->text +=textToAdd; + + WString addText(textToAdd); + appendText(addText.cw_str(), false, false); + updateAutoCompleteBuffer(); return true; }