diff options
| author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-06-05 10:48:25 +0100 |
|---|---|---|
| committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-06-05 10:48:25 +0100 |
| commit | 033f0dbdef5d23858065dcdcc2f70e5546f50651 (patch) | |
| tree | 8b02193738179cdd5b35919af8e0ea9311180e1e /indra/newview/llwearableitemslist.cpp | |
| parent | eec00a712fff079009ae793d86e27b7f3ab13053 (diff) | |
| parent | d1751df1cc5d9bf853f29555de94faec1912e19f (diff) | |
merge from PE's viewer-trunk
Diffstat (limited to 'indra/newview/llwearableitemslist.cpp')
| -rw-r--r-- | indra/newview/llwearableitemslist.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/indra/newview/llwearableitemslist.cpp b/indra/newview/llwearableitemslist.cpp index 6c4774ba5a..6c410cf7a5 100644 --- a/indra/newview/llwearableitemslist.cpp +++ b/indra/newview/llwearableitemslist.cpp @@ -42,6 +42,7 @@ #include "llmenugl.h" // for LLContextMenu #include "lltransutil.h" #include "llviewerattachmenu.h" +#include "llvoavatarself.h" class LLFindOutfitItems : public LLInventoryCollectFunctor { @@ -258,6 +259,31 @@ BOOL LLPanelDeletableWearableListItem::postBuild() } +// static +LLPanelAttachmentListItem* LLPanelAttachmentListItem::create(LLViewerInventoryItem* item) +{ + LLPanelAttachmentListItem* list_item = NULL; + if(item) + { + list_item = new LLPanelAttachmentListItem(item); + list_item->init(); + } + return list_item; +} + +void LLPanelAttachmentListItem::setTitle(const std::string& title, const std::string& highlit_text) +{ + std::string title_joint = title; + + if (mItem && isAgentAvatarValid() && gAgentAvatarp->isWearingAttachment(mItem->getLinkedUUID())) + { + std::string joint = LLTrans::getString(gAgentAvatarp->getAttachedPointName(mItem->getLinkedUUID())); + title_joint = title + " (" + joint + ")"; + } + + LLPanelDeletableWearableListItem::setTitle(title_joint, highlit_text); +} + ////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////// |
