summaryrefslogtreecommitdiff
path: root/indra/newview/llinventorybridge.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llinventorybridge.cpp')
-rw-r--r--indra/newview/llinventorybridge.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 0c092e9a56..244b001adb 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -195,6 +195,20 @@ BOOL LLInvFVBridge::isLink() const
return mIsLink;
}
+// Is a "System" folder
+// System folders are predefined named folders that have a specific preferred type
+// e.g. "Textures" which has an FT_TEXTURE preferred type.
+// Those are folders used to route incoming items in the current (soon to be obsolete) inventory
+// asset routing.
+// If a folder uses the same name as a predefined folder but is not of the same preferred type
+// or if it has a preferred type but a different name, it will not be considered a system folder.
+// *TODO: Test that logic in all languages
+bool LLInvFVBridge::isSystemFolder() const
+{
+ LLFolderType::EType preferred_type = getPreferredType();
+ return (preferred_type == LLFolderType::FT_NONE ? false : LLViewerFolderType::lookupTypeFromNewCategoryName(getDisplayName()) == preferred_type);
+}
+
/*virtual*/
/**
* @brief Adds this item into clipboard storage