summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llfilteredwearablelist.cpp16
-rw-r--r--indra/newview/llfilteredwearablelist.h2
2 files changed, 8 insertions, 10 deletions
diff --git a/indra/newview/llfilteredwearablelist.cpp b/indra/newview/llfilteredwearablelist.cpp
index 01d3c3f22e..fd99f673e0 100644
--- a/indra/newview/llfilteredwearablelist.cpp
+++ b/indra/newview/llfilteredwearablelist.cpp
@@ -37,23 +37,21 @@
#include "llinventoryitemslist.h"
#include "llinventorymodel.h"
-class LLFindItemsByMask : public LLInventoryCollectFunctor
+class LLFindNonLinksByMask : public LLInventoryCollectFunctor
{
public:
- LLFindItemsByMask(U64 mask)
+ LLFindNonLinksByMask(U64 mask)
: mFilterMask(mask)
{}
virtual bool operator()(LLInventoryCategory* cat, LLInventoryItem* item)
{
- if(item)
+ if(item && !item->getIsLinkType() && (mFilterMask & (1LL << item->getInventoryType())) )
{
- if( mFilterMask & (1LL << item->getInventoryType()) )
- {
- return TRUE;
- }
+ return true;
}
- return FALSE;
+
+ return false;
}
private:
@@ -96,7 +94,7 @@ void LLFilteredWearableListManager::populateList()
{
LLInventoryModel::cat_array_t cat_array;
LLInventoryModel::item_array_t item_array;
- LLFindItemsByMask collector(mFilterMask);
+ LLFindNonLinksByMask collector(mFilterMask);
gInventory.collectDescendentsIf(
gInventory.getRootFolderID(),
diff --git a/indra/newview/llfilteredwearablelist.h b/indra/newview/llfilteredwearablelist.h
index 3f42833bb4..0780c02442 100644
--- a/indra/newview/llfilteredwearablelist.h
+++ b/indra/newview/llfilteredwearablelist.h
@@ -36,7 +36,7 @@
class LLInventoryItemsList;
-// Class that fills LLInventoryItemsList with filtered data.
+// Class that fills LLInventoryItemsList with filtered data (original items only (non-links)).
class LLFilteredWearableListManager : public LLInventoryObserver
{
LOG_CLASS(LLFilteredWearableListManager);