summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2014-10-21 16:39:55 -0700
committerMerov Linden <merov@lindenlab.com>2014-10-21 16:39:55 -0700
commit511c77657963afa06819560b6eb2c4a6c224af72 (patch)
tree0bfb3f1f462480cbc03214b65466dfc625eefb2d /indra
parent78e3d40597301c0acae068529cf553856a8298fd (diff)
DD-220 : Avoid testing folders against marketplace root if we are not filtering against the marketplace
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/llinventoryfilter.cpp40
1 files changed, 22 insertions, 18 deletions
diff --git a/indra/newview/llinventoryfilter.cpp b/indra/newview/llinventoryfilter.cpp
index a649b515d1..07835f189c 100755
--- a/indra/newview/llinventoryfilter.cpp
+++ b/indra/newview/llinventoryfilter.cpp
@@ -136,33 +136,37 @@ bool LLInventoryFilter::checkFolder(const LLUUID& folder_id) const
}
// Marketplace folder filtering
- S32 depth = depth_nesting_in_marketplace(folder_id);
- if (depth > 0)
+ const U32 filterTypes = mFilterOps.mFilterTypes;
+ const U32 marketplace_filter = FILTERTYPE_MARKETPLACE_ACTIVE | FILTERTYPE_MARKETPLACE_INACTIVE | FILTERTYPE_MARKETPLACE_UNASSOCIATED;
+ if (filterTypes & marketplace_filter)
{
- const U32 filterTypes = mFilterOps.mFilterTypes;
- LLUUID listing_uuid = nested_parent_id(folder_id, depth);
- if (filterTypes & FILTERTYPE_MARKETPLACE_ACTIVE)
+ S32 depth = depth_nesting_in_marketplace(folder_id);
+ if (depth > 0)
{
- if (!LLMarketplaceData::instance().getActivationState(listing_uuid))
+ LLUUID listing_uuid = nested_parent_id(folder_id, depth);
+ if (filterTypes & FILTERTYPE_MARKETPLACE_ACTIVE)
{
- return false;
+ if (!LLMarketplaceData::instance().getActivationState(listing_uuid))
+ {
+ return false;
+ }
}
- }
- else if (filterTypes & FILTERTYPE_MARKETPLACE_INACTIVE)
- {
- if (!LLMarketplaceData::instance().isListed(listing_uuid) || LLMarketplaceData::instance().getActivationState(listing_uuid))
+ else if (filterTypes & FILTERTYPE_MARKETPLACE_INACTIVE)
{
- return false;
+ if (!LLMarketplaceData::instance().isListed(listing_uuid) || LLMarketplaceData::instance().getActivationState(listing_uuid))
+ {
+ return false;
+ }
}
- }
- else if (filterTypes & FILTERTYPE_MARKETPLACE_UNASSOCIATED)
- {
- if (LLMarketplaceData::instance().isListed(listing_uuid))
+ else if (filterTypes & FILTERTYPE_MARKETPLACE_UNASSOCIATED)
{
- return false;
+ if (LLMarketplaceData::instance().isListed(listing_uuid))
+ {
+ return false;
+ }
}
}
- }
+ }
// Always check against the clipboard
const BOOL passed_clipboard = checkAgainstClipboard(folder_id);