diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-03-01 10:23:56 -0500 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-03-01 10:23:56 -0500 |
commit | 1204468415dd5248bbd01d7aaede520ede3b9d36 (patch) | |
tree | b378b94ff7266ce5c7f719b3ba55c836837869e9 /indra/newview/llinventorygallery.cpp | |
parent | 0f2248ea12713822c546e362487aa94bb29e2899 (diff) | |
parent | 1820095dd4a64c142e14869c76ae09e1e0ca6a12 (diff) |
Merge DRTVWR-489 to main on promotion of Emoji viewer (#673).
Diffstat (limited to 'indra/newview/llinventorygallery.cpp')
-rw-r--r-- | indra/newview/llinventorygallery.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/indra/newview/llinventorygallery.cpp b/indra/newview/llinventorygallery.cpp index 68581d04eb..d4ca58f778 100644 --- a/indra/newview/llinventorygallery.cpp +++ b/indra/newview/llinventorygallery.cpp @@ -2402,11 +2402,17 @@ void LLInventoryGallery::startDrag() { std::vector<EDragAndDropType> types; uuid_vec_t ids; + LLToolDragAndDrop::ESource src = LLToolDragAndDrop::SOURCE_AGENT; for (LLUUID& selected_id : mSelectedItemIDs) { const LLInventoryItem* item = gInventory.getItem(selected_id); if (item) { + if (item->getPermissions().getOwner() == ALEXANDRIA_LINDEN_ID) + { + src = LLToolDragAndDrop::SOURCE_LIBRARY; + } + EDragAndDropType type = LLViewerAssetType::lookupDragAndDropType(item->getType()); types.push_back(type); ids.push_back(selected_id); @@ -2416,12 +2422,17 @@ void LLInventoryGallery::startDrag() if (cat && gInventory.isObjectDescendentOf(selected_id, gInventory.getRootFolderID()) && !LLFolderType::lookupIsProtectedType((cat)->getPreferredType())) { + if (cat->getOwnerID() == ALEXANDRIA_LINDEN_ID) + { + src = LLToolDragAndDrop::SOURCE_LIBRARY; + } + EDragAndDropType type = LLViewerAssetType::lookupDragAndDropType(cat->getType()); types.push_back(type); ids.push_back(selected_id); } } - LLToolDragAndDrop::getInstance()->beginMultiDrag(types, ids, LLToolDragAndDrop::SOURCE_AGENT); + LLToolDragAndDrop::getInstance()->beginMultiDrag(types, ids, src); } bool LLInventoryGallery::areViewsInitialized() |