diff options
author | Brad Linden <46733234+brad-linden@users.noreply.github.com> | 2024-06-12 14:33:01 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-12 14:33:01 -0700 |
commit | 071e464155a670a9a7e836ec52049fc80b507995 (patch) | |
tree | e129794d3f4c29c92d6515cbdbe6898ee8aa558b /indra/newview/llinventorygallerymenu.cpp | |
parent | f0de2ba6340e0d540aa70ac0086defde52cf60af (diff) | |
parent | 8444cd9562a6a7b755fcb075864e205122354192 (diff) |
Merge pull request #1723 from secondlife/brad/maint-a-merge-to-gltf-dev
maint a merge to gltf dev
Diffstat (limited to 'indra/newview/llinventorygallerymenu.cpp')
-rw-r--r-- | indra/newview/llinventorygallerymenu.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/indra/newview/llinventorygallerymenu.cpp b/indra/newview/llinventorygallerymenu.cpp index f9fb47c5c1..8e56ccc01d 100644 --- a/indra/newview/llinventorygallerymenu.cpp +++ b/indra/newview/llinventorygallerymenu.cpp @@ -110,6 +110,7 @@ LLContextMenu* LLInventoryGalleryContextMenu::createMenu() registrar.add("Inventory.Share", boost::bind(&LLAvatarActions::shareWithAvatars, uuids, gFloaterView->getParentFloater(mGallery))); enable_registrar.add("Inventory.CanSetUploadLocation", boost::bind(&LLInventoryGalleryContextMenu::canSetUploadLocation, this, _2)); + enable_registrar.add("Inventory.EnvironmentEnabled", [](LLUICtrl*, const LLSD&) { return LLEnvironment::instance().isInventoryEnabled(); @@ -121,7 +122,7 @@ LLContextMenu* LLInventoryGalleryContextMenu::createMenu() return (!agent_url.empty() && !task_url.empty()); }); - + LLContextMenu* menu = createFromFile("menu_gallery_inventory.xml"); updateMenuItemsVisibility(menu); @@ -448,7 +449,7 @@ void LLInventoryGalleryContextMenu::onRename(const LLSD& notification, const LLS if (!new_name.empty()) { LLUUID id = notification["payload"]["id"].asUUID(); - + LLViewerInventoryCategory* cat = gInventory.getCategory(id); if(cat && (cat->getName() != new_name)) { @@ -457,7 +458,7 @@ void LLInventoryGalleryContextMenu::onRename(const LLSD& notification, const LLS update_inventory_category(cat->getUUID(),updates, NULL); return; } - + LLViewerInventoryItem* item = gInventory.getItem(id); if(item && (item->getName() != new_name)) { @@ -506,12 +507,12 @@ bool LLInventoryGalleryContextMenu::canSetUploadLocation(const LLSD& userdata) bool is_inbox_folder(LLUUID item_id) { const LLUUID inbox_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX); - + if (inbox_id.isNull()) { return false; } - + return gInventory.isObjectDescendentOf(item_id, inbox_id); } @@ -865,7 +866,7 @@ void LLInventoryGalleryContextMenu::updateMenuItemsVisibility(LLContextMenu* men disabled_items.push_back(std::string("Open")); disabled_items.push_back(std::string("Open Original")); } - + if(LLAssetType::AT_GESTURE == obj->getType()) { items.push_back(std::string("Gesture Separator")); |