diff options
author | Kent Quirk <q@lindenlab.com> | 2009-01-05 18:59:12 +0000 |
---|---|---|
committer | Kent Quirk <q@lindenlab.com> | 2009-01-05 18:59:12 +0000 |
commit | 667ca55bad0108c4bdf8f007b89e1a52fc766aad (patch) | |
tree | 7bd62ac8d9af079c3994565f3f200ccc250bbc28 /indra/newview/llmutelist.cpp | |
parent | 95f365789f4cebc7bd97ccefd538f14d481a8373 (diff) |
svn merge -r106715:HEAD svn+ssh://svn.lindenlab.com/svn/linden/branches/q/notifications-merge-r106715 . QAR-1149 -- Final merge of notifications to trunk.
Diffstat (limited to 'indra/newview/llmutelist.cpp')
-rw-r--r-- | indra/newview/llmutelist.cpp | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/indra/newview/llmutelist.cpp b/indra/newview/llmutelist.cpp index 3ad26b703a..cc9be04cfc 100644 --- a/indra/newview/llmutelist.cpp +++ b/indra/newview/llmutelist.cpp @@ -66,7 +66,8 @@ #include "llfloaterchat.h" #include "llimpanel.h" #include "llimview.h" -#include "llnotify.h" +#include "lltrans.h" +#include "llnotifications.h" #include "lluistring.h" #include "llviewerobject.h" #include "llviewerobjectlist.h" @@ -278,7 +279,7 @@ BOOL LLMuteList::add(const LLMute& mute, U32 flags) if ((mute.mType == LLMute::AGENT) && isLinden(mute.mName) && (flags & LLMute::flagTextChat || flags == 0)) { - gViewerWindow->alertXml("MuteLinden"); + LLNotifications::instance().add("MuteLinden"); return FALSE; } @@ -480,35 +481,35 @@ void notify_automute_callback(const LLUUID& agent_id, const std::string& first_n { U32 temp_data = (U32) (uintptr_t) user_data; LLMuteList::EAutoReason reason = (LLMuteList::EAutoReason)temp_data; - LLUIString auto_message; - + + std::string auto_message; switch (reason) { default: case LLMuteList::AR_IM: - auto_message = LLNotifyBox::getTemplateMessage("AutoUnmuteByIM"); + auto_message = LLTrans::getString("AutoUnmuteByIM"); break; case LLMuteList::AR_INVENTORY: - auto_message = LLNotifyBox::getTemplateMessage("AutoUnmuteByInventory"); + auto_message = LLTrans::getString("AutoUnmuteByInventory"); break; case LLMuteList::AR_MONEY: - auto_message = LLNotifyBox::getTemplateMessage("AutoUnmuteByMoney"); + auto_message = LLTrans::getString("AutoUnmuteByMoney"); break; } - auto_message.setArg("[FIRST]", first_name); - auto_message.setArg("[LAST]", last_name); + std::string message = LLNotification::format(auto_message, + LLSD().insert("FIRST", first_name).insert("LAST", last_name)); if (reason == LLMuteList::AR_IM) { LLFloaterIMPanel *timp = gIMMgr->findFloaterBySession(agent_id); if (timp) { - timp->addHistoryLine(auto_message.getString()); + timp->addHistoryLine(message); } } - LLChat auto_chat(auto_message.getString()); + LLChat auto_chat(message); LLFloaterChat::addChat(auto_chat, FALSE, FALSE); } |