summaryrefslogtreecommitdiff
path: root/indra/newview/llinventorygallery.cpp
diff options
context:
space:
mode:
authorBrad Linden <brad@lindenlab.com>2024-04-24 09:55:34 -0700
committerBrad Linden <brad@lindenlab.com>2024-04-24 09:55:34 -0700
commit86c0c1d5536897c925f4e8aa2859a160313d964c (patch)
tree9d32be1b0d6a4dd139d8a72b35a94f48046b2ffc /indra/newview/llinventorygallery.cpp
parentcadc1a02cc7289dabd368dd1a1d237c042e9f82e (diff)
parentd98fc504a1d4bc292ba86acdda053c8b4598a193 (diff)
Merge remote-tracking branch 'origin/main' into release/materials_featurette
Diffstat (limited to 'indra/newview/llinventorygallery.cpp')
-rw-r--r--indra/newview/llinventorygallery.cpp21
1 files changed, 13 insertions, 8 deletions
diff --git a/indra/newview/llinventorygallery.cpp b/indra/newview/llinventorygallery.cpp
index d4ca58f778..230ee86fb7 100644
--- a/indra/newview/llinventorygallery.cpp
+++ b/indra/newview/llinventorygallery.cpp
@@ -2419,17 +2419,22 @@ void LLInventoryGallery::startDrag()
}
const LLViewerInventoryCategory* cat = gInventory.getCategory(selected_id);
- if (cat && gInventory.isObjectDescendentOf(selected_id, gInventory.getRootFolderID())
- && !LLFolderType::lookupIsProtectedType((cat)->getPreferredType()))
+ if (cat)
{
- if (cat->getOwnerID() == ALEXANDRIA_LINDEN_ID)
+ if (gInventory.isObjectDescendentOf(selected_id, gInventory.getLibraryRootFolderID()))
{
src = LLToolDragAndDrop::SOURCE_LIBRARY;
+ EDragAndDropType type = LLViewerAssetType::lookupDragAndDropType(cat->getType());
+ types.push_back(type);
+ ids.push_back(selected_id);
+ }
+ else if (gInventory.isObjectDescendentOf(selected_id, gInventory.getRootFolderID())
+ && !LLFolderType::lookupIsProtectedType((cat)->getPreferredType()))
+ {
+ EDragAndDropType type = LLViewerAssetType::lookupDragAndDropType(cat->getType());
+ types.push_back(type);
+ ids.push_back(selected_id);
}
-
- EDragAndDropType type = LLViewerAssetType::lookupDragAndDropType(cat->getType());
- types.push_back(type);
- ids.push_back(selected_id);
}
}
LLToolDragAndDrop::getInstance()->beginMultiDrag(types, ids, src);
@@ -3334,7 +3339,7 @@ BOOL dragItemIntoFolder(LLUUID folder_id, LLInventoryItem* inv_item, BOOL drop,
if (accept && drop)
{
- boost::shared_ptr<LLMoveInv> move_inv (new LLMoveInv());
+ std::shared_ptr<LLMoveInv> move_inv (new LLMoveInv());
move_inv->mObjectID = inv_item->getParentUUID();
std::pair<LLUUID, LLUUID> item_pair(folder_id, inv_item->getUUID());
move_inv->mMoveList.push_back(item_pair);