diff options
author | McCabe Maxsted | 2010-05-11 10:34:51 -0700 |
---|---|---|
committer | Jacek Antonelli | 2010-06-19 02:05:24 -0500 |
commit | e9fd76ce2fbc6b53acb95b8cee8a266c0060c8fd (patch) | |
tree | 365b79e5c3e1de972bb7c44d264e6880deb8108a /linden/indra/newview/llpanelavatar.cpp | |
parent | Backported llimage changes from Viewer 2.0.0 (diff) | |
download | meta-impy-e9fd76ce2fbc6b53acb95b8cee8a266c0060c8fd.zip meta-impy-e9fd76ce2fbc6b53acb95b8cee8a266c0060c8fd.tar.gz meta-impy-e9fd76ce2fbc6b53acb95b8cee8a266c0060c8fd.tar.bz2 meta-impy-e9fd76ce2fbc6b53acb95b8cee8a266c0060c8fd.tar.xz |
Implemented #270: Say the name of the avatar and key copied in chat when Copy Key is pressed
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llpanelavatar.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/linden/indra/newview/llpanelavatar.cpp b/linden/indra/newview/llpanelavatar.cpp index 5d01154..dbdeb3c 100644 --- a/linden/indra/newview/llpanelavatar.cpp +++ b/linden/indra/newview/llpanelavatar.cpp | |||
@@ -50,6 +50,7 @@ | |||
50 | #include "llcheckboxctrl.h" | 50 | #include "llcheckboxctrl.h" |
51 | #include "llfloater.h" | 51 | #include "llfloater.h" |
52 | 52 | ||
53 | #include "llfloaterchat.h" | ||
53 | #include "llfloaterfriends.h" | 54 | #include "llfloaterfriends.h" |
54 | #include "llfloatergroupinfo.h" | 55 | #include "llfloatergroupinfo.h" |
55 | #include "llfloatergroups.h" | 56 | #include "llfloatergroups.h" |
@@ -1623,6 +1624,18 @@ void LLPanelAvatar::onClickCopyUUID(void *userdata) | |||
1623 | { | 1624 | { |
1624 | LLPanelAvatar* self = (LLPanelAvatar*) userdata; | 1625 | LLPanelAvatar* self = (LLPanelAvatar*) userdata; |
1625 | 1626 | ||
1627 | // Say same info in chat -- MC | ||
1628 | LLStringUtil::format_map_t targs; | ||
1629 | targs["[KEY]"] = self->mAvatarID.asString(); | ||
1630 | targs["[AVATAR]"] = self->mPanelSecondLife->getChild<LLNameEditor>("name")->getText(); | ||
1631 | std::string msg = self->mPanelSecondLife->getString("copy_key_info"); | ||
1632 | LLStringUtil::format(msg, targs); | ||
1633 | |||
1634 | LLChat chat; | ||
1635 | chat.mSourceType = CHAT_SOURCE_SYSTEM; | ||
1636 | chat.mText = msg; | ||
1637 | LLFloaterChat::addChat(chat); | ||
1638 | |||
1626 | std::string buffer; | 1639 | std::string buffer; |
1627 | (self->mAvatarID).toString(buffer); | 1640 | (self->mAvatarID).toString(buffer); |
1628 | gViewerWindow->mWindow->copyTextToClipboard(utf8str_to_wstring(buffer)); | 1641 | gViewerWindow->mWindow->copyTextToClipboard(utf8str_to_wstring(buffer)); |