From 0c0f7558782edccda375609777967184b8440441 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Mon, 6 Jun 2011 16:30:22 -0700 Subject: fixing drag and drop for inbox, adding inbox text and cleaning up context menus --- indra/newview/llinventorybridge.cpp | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'indra/newview/llinventorybridge.cpp') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index bdb9f6167a..20a187c302 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -572,7 +572,7 @@ void LLInvFVBridge::getClipboardEntries(bool show_asset_id, } // Don't allow items to be pasted directly into the COF. - if (!isCOFFolder()) + if (!isCOFFolder() && !isInboxFolder()) { items.push_back(std::string("Paste")); } @@ -781,6 +781,11 @@ BOOL LLInvFVBridge::isCOFFolder() const return LLAppearanceMgr::instance().getIsInCOF(mUUID); } +BOOL LLInvFVBridge::isInboxFolder() const +{ + return gInventory.isObjectDescendentOf(mUUID, gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX)); +} + BOOL LLInvFVBridge::isItemPermissive() const { return FALSE; @@ -2601,7 +2606,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags) LLViewerInventoryCategory *cat = getCategory(); // BAP removed protected check to re-enable standard ops in untyped folders. // Not sure what the right thing is to do here. - if (!isCOFFolder() && cat && (cat->getPreferredType() != LLFolderType::FT_OUTFIT)) + if (!isCOFFolder() && !isInboxFolder() && cat && (cat->getPreferredType() != LLFolderType::FT_OUTFIT)) { // Do not allow to create 2-level subfolder in the Calling Card/Friends folder. EXT-694. if (!LLFriendCardsManager::instance().isCategoryInFriendFolder(cat)) @@ -2627,7 +2632,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags) else { // Want some but not all of the items from getClipboardEntries for outfits. - if (cat && (cat->getPreferredType() == LLFolderType::FT_OUTFIT)) + if (cat && (cat->getPreferredType() == LLFolderType::FT_OUTFIT) || (cat->getPreferredType() == LLFolderType::FT_INBOX)) { mItems.push_back(std::string("Rename")); @@ -4298,7 +4303,7 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags) items.push_back(std::string("Wearable And Object Separator")); items.push_back(std::string("Detach From Yourself")); } - else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder()) + else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder() && !isInboxFolder()) { items.push_back(std::string("Wearable And Object Separator")); items.push_back(std::string("Wearable And Object Wear")); @@ -4650,7 +4655,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags) disabled_items.push_back(std::string("Wearable Edit")); } // Don't allow items to be worn if their baseobj is in the trash. - if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder()) + if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder() || isInboxFolder()) { disabled_items.push_back(std::string("Wearable And Object Wear")); disabled_items.push_back(std::string("Wearable Add")); -- cgit v1.2.3 From f42d2607be4aad88f432346787e556836b58a757 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Thu, 16 Jun 2011 16:38:31 -0700 Subject: EXP-905 Missing items from right click context menus in My Inbox EXP-892 No way to delete items in Inbox without moving them to Inventory --- indra/newview/llinventorybridge.cpp | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) (limited to 'indra/newview/llinventorybridge.cpp') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 88475bd942..f4670731ad 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -571,7 +571,7 @@ void LLInvFVBridge::getClipboardEntries(bool show_asset_id, } } - // Don't allow items to be pasted directly into the COF. + // Don't allow items to be pasted directly into the COF or the inbox if (!isCOFFolder() && !isInboxFolder()) { items.push_back(std::string("Paste")); @@ -2530,6 +2530,7 @@ void LLFolderBridge::folderOptionsMenu() { mItems.push_back(std::string("Add To Outfit")); } + mItems.push_back(std::string("Replace Outfit")); } if (is_ensemble) @@ -2617,17 +2618,19 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags) LLViewerInventoryCategory *cat = getCategory(); // BAP removed protected check to re-enable standard ops in untyped folders. // Not sure what the right thing is to do here. - if (!isCOFFolder() && !isInboxFolder() && cat && (cat->getPreferredType() != LLFolderType::FT_OUTFIT)) + if (!isCOFFolder() && cat && (cat->getPreferredType() != LLFolderType::FT_OUTFIT)) { - // Do not allow to create 2-level subfolder in the Calling Card/Friends folder. EXT-694. - if (!LLFriendCardsManager::instance().isCategoryInFriendFolder(cat)) - mItems.push_back(std::string("New Folder")); - mItems.push_back(std::string("New Script")); - mItems.push_back(std::string("New Note")); - mItems.push_back(std::string("New Gesture")); - mItems.push_back(std::string("New Clothes")); - mItems.push_back(std::string("New Body Parts")); - + if (!isInboxFolder()) // don't allow creation in inbox + { + // Do not allow to create 2-level subfolder in the Calling Card/Friends folder. EXT-694. + if (!LLFriendCardsManager::instance().isCategoryInFriendFolder(cat)) + mItems.push_back(std::string("New Folder")); + mItems.push_back(std::string("New Script")); + mItems.push_back(std::string("New Note")); + mItems.push_back(std::string("New Gesture")); + mItems.push_back(std::string("New Clothes")); + mItems.push_back(std::string("New Body Parts")); + } #if SUPPORT_ENSEMBLES // Changing folder types is an unfinished unsupported feature // and can lead to unexpected behavior if enabled. @@ -2643,7 +2646,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags) else { // Want some but not all of the items from getClipboardEntries for outfits. - if (cat && (cat->getPreferredType() == LLFolderType::FT_OUTFIT) || (cat->getPreferredType() == LLFolderType::FT_INBOX)) + if (cat && (cat->getPreferredType() == LLFolderType::FT_OUTFIT)) { mItems.push_back(std::string("Rename")); @@ -4320,7 +4323,7 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags) items.push_back(std::string("Wearable And Object Separator")); items.push_back(std::string("Detach From Yourself")); } - else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder() && !isInboxFolder()) + else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder()) { items.push_back(std::string("Wearable And Object Separator")); items.push_back(std::string("Wearable And Object Wear")); @@ -4672,7 +4675,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags) disabled_items.push_back(std::string("Wearable Edit")); } // Don't allow items to be worn if their baseobj is in the trash. - if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder() || isInboxFolder()) + if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder()) { disabled_items.push_back(std::string("Wearable And Object Wear")); disabled_items.push_back(std::string("Wearable Add")); -- cgit v1.2.3 From 8737446eb737bc26dcb1ac9462cc060baef0e13f Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Wed, 22 Jun 2011 14:28:19 -0400 Subject: EXP-919 FIX -- Toggling InventoryDisplayInbox value to True in Viewer on Agni creates Inbox and Outbox system folders * The code should no longer create these folders when querying for them. Reviewed by Richard --- indra/newview/llinventorybridge.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'indra/newview/llinventorybridge.cpp') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index f4670731ad..58579bdf4f 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -783,7 +783,14 @@ BOOL LLInvFVBridge::isCOFFolder() const BOOL LLInvFVBridge::isInboxFolder() const { - return gInventory.isObjectDescendentOf(mUUID, gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX)); + const LLUUID inbox_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX, false, false); + + if (inbox_id.isNull()) + { + return FALSE; + } + + return gInventory.isObjectDescendentOf(mUUID, inbox_id); } BOOL LLInvFVBridge::isItemPermissive() const -- cgit v1.2.3 From 8c6e6c305850f196e0eed7ebb4bf8aa528613fa4 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Wed, 29 Jun 2011 15:24:05 -0700 Subject: EXP-895 Selecting items in Marketplace Inbox does not change focus in inventory panel away from items selected in inventory panel --- indra/newview/llinventorybridge.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'indra/newview/llinventorybridge.cpp') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 58579bdf4f..6644eea219 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -1798,6 +1798,10 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat, } else { + if (gInventory.isObjectDescendentOf(inv_cat->getUUID(), gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX, false, false))) + { + set_dad_inbox_object(inv_cat->getUUID()); + } // Reparent the folder and restamp children if it's moving // into trash. @@ -3176,6 +3180,12 @@ BOOL LLFolderBridge::dragItemIntoFolder(LLInventoryItem* inv_item, // (move the item, restamp if into trash) else { + // set up observer to select item once drag and drop from inbox is complete + if (gInventory.isObjectDescendentOf(inv_item->getUUID(), gInventory.findCategoryUUIDForType(LLFolderType::FT_INBOX, false, false))) + { + set_dad_inbox_object(inv_item->getUUID()); + } + LLInvFVBridge::changeItemParent( model, (LLViewerInventoryItem*)inv_item, -- cgit v1.2.3 From e92d3dcf1013ab340fdef514b41ebf790f79e04c Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Tue, 5 Jul 2011 23:40:19 -0700 Subject: EXP-971 FIX New Direct Delivery item does not sort as most recent item in Recent Tab if that tab is open when item delivered --- indra/newview/llinventorybridge.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llinventorybridge.cpp') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 6644eea219..75d4c4e80d 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -40,6 +40,7 @@ #include "llfloateropenobject.h" #include "llfloaterreg.h" #include "llfloaterworldmap.h" +#include "llfolderview.h" #include "llfriendcard.h" #include "llgesturemgr.h" #include "llgiveinventory.h" -- cgit v1.2.3