diff options
| author | 2008-08-28 12:45:50 +0000 | |
|---|---|---|
| committer | 2008-08-28 12:45:50 +0000 | |
| commit | 34b53f2c183d91bacce49d2b21a23e9cb3265046 (patch) | |
| tree | 9d937288d9c9592c3887eb3b9601af6af41e60d0 /src/modules/dcc/chat.cpp | |
| parent | an option to place nicks starting with non-alpha chars (such as _COOL_BOY_) a... (diff) | |
| download | KVIrc-34b53f2c183d91bacce49d2b21a23e9cb3265046.tar.gz KVIrc-34b53f2c183d91bacce49d2b21a23e9cb3265046.tar.bz2 KVIrc-34b53f2c183d91bacce49d2b21a23e9cb3265046.zip | |
upported fix for #220
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@2333 17fca916-40b9-46aa-a4ea-0a15b648b75c
Diffstat (limited to 'src/modules/dcc/chat.cpp')
| -rw-r--r-- | src/modules/dcc/chat.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/modules/dcc/chat.cpp b/src/modules/dcc/chat.cpp index cda540b2e..643b2e44b 100644 --- a/src/modules/dcc/chat.cpp +++ b/src/modules/dcc/chat.cpp @@ -375,12 +375,21 @@ void KviDccChat::ownAction(const QString &text) { if(m_pSlaveThread) { - KviQCString szData = encodeText(text); + QString szTmpBuffer; + //see bug ticket #220 + if(KVI_OPTION_BOOL(KviOption_boolStripMircColorsInUserMessages)) + { + szTmpBuffer = KviMircCntrl::stripControlBytes(text); + } else { + szTmpBuffer = text; + } + + KviQCString szData = encodeText(szTmpBuffer); const char * d = szData.data(); if(!d)return; KviStr buf(KviStr::Format,"%cACTION %s%c\r\n",0x01,d,0x01); m_pSlaveThread->sendRawData(buf.ptr(),buf.len()); - output(KVI_OUT_ACTION,"%Q %Q",&(m_pDescriptor->szLocalNick),&text); + output(KVI_OUT_ACTION,"%Q %Q",&(m_pDescriptor->szLocalNick),&szTmpBuffer); } else { output(KVI_OUT_SYSTEMWARNING,__tr2qs_ctx("Cannot send data: No active connection","dcc")); } |
