summaryrefslogtreecommitdiff
path: root/src/chat.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/chat.cpp')
-rw-r--r--src/chat.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/chat.cpp b/src/chat.cpp
index 0466b6e26..b78b90145 100644
--- a/src/chat.cpp
+++ b/src/chat.cpp
@@ -407,6 +407,15 @@ void ChatPrompt::input(wchar_t ch)
m_nick_completion_end = 0;
}
+void ChatPrompt::input(const std::wstring &str)
+{
+ m_line.insert(m_cursor, str);
+ m_cursor += str.size();
+ clampView();
+ m_nick_completion_start = 0;
+ m_nick_completion_end = 0;
+}
+
std::wstring ChatPrompt::submit()
{
std::wstring line = m_line;