diff options
| author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-03-15 15:23:28 +0000 |
|---|---|---|
| committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-03-15 15:23:28 +0000 |
| commit | 42d1aaee2e3a9c5df3e7b4ace3bf6b5972a74847 (patch) | |
| tree | 81c20219c87f23b5f9cce34099cf1db6d68709cd /indra/newview/llviewermessage.cpp | |
| parent | 234cd6e7c04c0840be6ae4a74eaf138e72876f44 (diff) | |
| parent | 8a8e8e46ee0564ac052c5fecaa1117db19f41c97 (diff) | |
PE merge.
Diffstat (limited to 'indra/newview/llviewermessage.cpp')
| -rw-r--r-- | indra/newview/llviewermessage.cpp | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 361f4e2326..b90e3dcda4 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -4458,20 +4458,37 @@ void process_money_balance_reply( LLMessageSystem* msg, void** ) // have missed something during an event. // *TODO: Translate LLSD args; - args["MESSAGE"] = desc; + // this is a marker to retrieve avatar name from server message: // "<avatar name> paid you L$" const std::string marker = "paid you L$"; + args["MESSAGE"] = desc; + // extract avatar name from system message - std::string name = desc.substr(0, desc.find(marker, 0)); + S32 marker_pos = desc.find(marker, 0); + + std::string base_name = desc.substr(0, marker_pos); + + std::string name = base_name; LLStringUtil::trim(name); // if name extracted and name cache contains avatar id send loggable notification LLUUID from_id; if(name.size() > 0 && gCacheName->getUUID(name, from_id)) { + //description always comes not localized. lets fix this + + //ammount paid + std::string ammount = desc.substr(marker_pos + marker.length(),desc.length() - marker.length() - marker_pos); + + //reform description + std::string paid_you = LLTrans::getString("paid_you_ldollars"); + std::string new_description = base_name + paid_you + ammount; + + args["MESSAGE"] = new_description; + args["NAME"] = name; LLSD payload; payload["from_id"] = from_id; |
