summaryrefslogtreecommitdiff
path: root/indra/newview/llinventoryfunctions.h
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2024-03-26 16:55:32 -0400
committerNat Goodspeed <nat@lindenlab.com>2024-03-26 16:55:32 -0400
commitc810a409e22b90ebacb9946f8a4084ef0ad78d64 (patch)
tree9fc508213bd00db70fc7aba7f3d4995541266f11 /indra/newview/llinventoryfunctions.h
parent656d1826e665b477e85ec3cf6db07677a3b88852 (diff)
parentdd74c2cbd542daa8d6cedba7ba7a68268f7b73d3 (diff)
Merge GLTF PBR Maint 2 to main.
Diffstat (limited to 'indra/newview/llinventoryfunctions.h')
-rw-r--r--indra/newview/llinventoryfunctions.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/indra/newview/llinventoryfunctions.h b/indra/newview/llinventoryfunctions.h
index 925217dda3..2056a7f6a3 100644
--- a/indra/newview/llinventoryfunctions.h
+++ b/indra/newview/llinventoryfunctions.h
@@ -278,6 +278,28 @@ protected:
LLAssetType::EType mType;
};
+//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+// Class LLAssetIDAndTypeMatches
+//
+// Implementation of a LLInventoryCollectFunctor which returns TRUE if
+// the item matches both asset type and asset id.
+// This is needed in case you are looking for a specific type with default id
+// (since null is default for multiple asset types)
+//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+class LLAssetIDAndTypeMatches: public LLInventoryCollectFunctor
+{
+public:
+ LLAssetIDAndTypeMatches(const LLUUID& asset_id, LLAssetType::EType type): mAssetID(asset_id), mType(type) {}
+ virtual ~LLAssetIDAndTypeMatches() {}
+ bool operator()(LLInventoryCategory* cat,
+ LLInventoryItem* item);
+
+protected:
+ LLUUID mAssetID;
+ LLAssetType::EType mType;
+};
+
class LLIsValidItemLink : public LLInventoryCollectFunctor
{
public: