summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2014-05-21 19:13:38 -0700
committerMerov Linden <merov@lindenlab.com>2014-05-21 19:13:38 -0700
commit78e13085eb0d95d98e2602779b34952bf4495e2f (patch)
treebc9bdeae2e5bc2aa71a61d556c29d436cd1f45aa /indra
parent2a6ce118882b7ac4ce533dcd3c74f582e01bdb29 (diff)
DD-91 : WIP : Fix taking the correct root folder (merchant outbox or marketplace listings) into account
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/llinventorybridge.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index bbd3f383eb..3715865a69 100755
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -2518,7 +2518,8 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
}
if (is_movable && (move_is_into_outbox || move_is_into_marketplacelistings))
{
- const int nested_folder_levels = get_folder_path_length(outbox_id, mUUID) + get_folder_levels(inv_cat);
+ int nested_folder_levels = get_folder_levels(inv_cat);
+ nested_folder_levels += (move_is_into_outbox ? get_folder_path_length(outbox_id, mUUID) : get_folder_path_length(marketplacelistings_id, mUUID));
if (nested_folder_levels > gSavedSettings.getU32("InventoryOutboxMaxFolderDepth"))
{
@@ -2534,7 +2535,7 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
int existing_item_count = 0;
int existing_folder_count = 0;
- const LLViewerInventoryCategory * master_folder = model->getFirstDescendantOf(outbox_id, mUUID);
+ const LLViewerInventoryCategory * master_folder = (move_is_into_outbox ? model->getFirstDescendantOf(outbox_id, mUUID) : model->getFirstDescendantOf(marketplacelistings_id, mUUID));
if (master_folder != NULL)
{
@@ -4378,7 +4379,7 @@ BOOL LLFolderBridge::dragItemIntoFolder(LLInventoryItem* inv_item,
if (accept)
{
- const LLViewerInventoryCategory * master_folder = model->getFirstDescendantOf(outbox_id, mUUID);
+ const LLViewerInventoryCategory * master_folder = (move_is_into_outbox ? model->getFirstDescendantOf(outbox_id, mUUID) : model->getFirstDescendantOf(marketplacelistings_id, mUUID));
int existing_item_count = LLToolDragAndDrop::instance().getCargoCount();