aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra
diff options
context:
space:
mode:
authorMcCabe Maxsted2010-09-08 14:26:03 -0700
committerMcCabe Maxsted2010-09-10 19:08:52 -0700
commit8e52ade6dd3aaeb33b18d8a99a169633f472b973 (patch)
tree18557dac148e67a4385db914ed327790d7ea138c /linden/indra
parentChanged the menu enabled 'x' to a checkmark (diff)
downloadmeta-impy-8e52ade6dd3aaeb33b18d8a99a169633f472b973.zip
meta-impy-8e52ade6dd3aaeb33b18d8a99a169633f472b973.tar.gz
meta-impy-8e52ade6dd3aaeb33b18d8a99a169633f472b973.tar.bz2
meta-impy-8e52ade6dd3aaeb33b18d8a99a169633f472b973.tar.xz
Ported use group name in chat feature from Emerald
Diffstat (limited to 'linden/indra')
-rw-r--r--linden/indra/newview/app_settings/settings.xml11
-rwxr-xr-xlinden/indra/newview/llviewermessage.cpp12
2 files changed, 22 insertions, 1 deletions
diff --git a/linden/indra/newview/app_settings/settings.xml b/linden/indra/newview/app_settings/settings.xml
index 333a780..667f0ad 100644
--- a/linden/indra/newview/app_settings/settings.xml
+++ b/linden/indra/newview/app_settings/settings.xml
@@ -772,6 +772,17 @@
772 <key>Value</key> 772 <key>Value</key>
773 <integer>0</integer> 773 <integer>0</integer>
774 </map> 774 </map>
775 <key>ShowGroupNameInChatIM</key>
776 <map>
777 <key>Comment</key>
778 <string>Show the group name when receiving group IMs</string>
779 <key>Persist</key>
780 <integer>1</integer>
781 <key>Type</key>
782 <string>Boolean</string>
783 <key>Value</key>
784 <integer>1</integer>
785 </map>
775 <key>ShowMiniMapRadar</key> 786 <key>ShowMiniMapRadar</key>
776 <map> 787 <map>
777 <key>Comment</key> 788 <key>Comment</key>
diff --git a/linden/indra/newview/llviewermessage.cpp b/linden/indra/newview/llviewermessage.cpp
index 56aed12..ec6d4d4 100755
--- a/linden/indra/newview/llviewermessage.cpp
+++ b/linden/indra/newview/llviewermessage.cpp
@@ -2313,7 +2313,17 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
2313 position, 2313 position,
2314 true); 2314 true);
2315 2315
2316 chat.mText = std::string("IM: ") + name + separator_string + saved + message.substr(message_offset); 2316 std::string group_name;
2317 if (gAgent.isInGroup(session_id) && gSavedSettings.getBOOL("ShowGroupNameInChatIM"))
2318 {
2319 group_name = std::string((char*)binary_bucket);
2320 chat.mText = std::string("[") + group_name + std::string("] ") + name
2321 + separator_string + saved + message.substr(message_offset);
2322 }
2323 else
2324 {
2325 chat.mText = std::string("IM: ") + name + separator_string + saved + message.substr(message_offset);
2326 }
2317 LLFloaterChat::addChat(chat, TRUE, is_this_agent); 2327 LLFloaterChat::addChat(chat, TRUE, is_this_agent);
2318 } 2328 }
2319 break; 2329 break;