From 1baf1d218644ac5dc00d9b41119a1ef168c709a2 Mon Sep 17 00:00:00 2001 From: angela Date: Mon, 16 Nov 2009 20:46:40 +0800 Subject: fix chat format for /me --- indra/newview/llviewerchat.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'indra/newview/llviewerchat.cpp') diff --git a/indra/newview/llviewerchat.cpp b/indra/newview/llviewerchat.cpp index d65a060bbc..ccf9ce9056 100644 --- a/indra/newview/llviewerchat.cpp +++ b/indra/newview/llviewerchat.cpp @@ -201,3 +201,20 @@ S32 LLViewerChat::getChatFontSize() { return gSavedSettings.getS32("ChatFontSize"); } + + +//static +void LLViewerChat::formatChatMsg(const LLChat& chat, std::string& formated_msg) +{ + std::string tmpmsg = chat.mText; + + if(chat.mChatStyle == CHAT_STYLE_IRC) + { + formated_msg = chat.mFromName + tmpmsg.substr(3); + } + else + { + formated_msg = tmpmsg; + } + +} \ No newline at end of file -- cgit v1.2.3 From 65efbae9af42661e8ccb814c3d7595c9d5bf2752 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Tue, 17 Nov 2009 16:23:59 +0000 Subject: magickal newline to unbreak linux. --- indra/newview/llviewerchat.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'indra/newview/llviewerchat.cpp') diff --git a/indra/newview/llviewerchat.cpp b/indra/newview/llviewerchat.cpp index ccf9ce9056..8de87eb602 100644 --- a/indra/newview/llviewerchat.cpp +++ b/indra/newview/llviewerchat.cpp @@ -217,4 +217,5 @@ void LLViewerChat::formatChatMsg(const LLChat& chat, std::string& formated_msg) formated_msg = tmpmsg; } -} \ No newline at end of file +} + -- cgit v1.2.3