summaryrefslogtreecommitdiff
path: root/indra/newview/llinventoryfunctions.cpp
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2015-08-25 11:40:36 -0700
committerRider Linden <rider@lindenlab.com>2015-08-25 11:40:36 -0700
commit96bb17f20bbcdc595f3a615a3129e134595b3a4a (patch)
treee51e47f79b78a076e821360763196cc72c154aad /indra/newview/llinventoryfunctions.cpp
parent7c61728b4bae928b2461f0f933dd1c1fa34ef0aa (diff)
parent1be63209331d509396bd7ee79302d511fe83d72e (diff)
Merge
Diffstat (limited to 'indra/newview/llinventoryfunctions.cpp')
-rwxr-xr-xindra/newview/llinventoryfunctions.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp
index 95db0d882e..916e9ad8f3 100755
--- a/indra/newview/llinventoryfunctions.cpp
+++ b/indra/newview/llinventoryfunctions.cpp
@@ -737,7 +737,7 @@ void show_item_original(const LLUUID& item_uuid)
{
return;
}
- active_panel->setSelection(gInventory.getLinkedItemID(item_uuid), TAKE_FOCUS_NO);
+ active_panel->setSelection(gInventory.getLinkedItemID(item_uuid), TAKE_FOCUS_YES);
if(do_reset_inventory_filter)
{
@@ -2473,7 +2473,7 @@ void LLInventoryAction::doToSelected(LLInventoryModel* model, LLFolderView* root
{
LLSD args;
args["QUESTION"] = LLTrans::getString(root->getSelectedCount() > 1 ? "DeleteItems" : "DeleteItem");
- LLNotificationsUtil::add("DeleteItems", args, LLSD(), boost::bind(&LLInventoryAction::onItemsRemovalConfirmation, _1, _2, root));
+ LLNotificationsUtil::add("DeleteItems", args, LLSD(), boost::bind(&onItemsRemovalConfirmation, _1, _2, root->getHandle()));
// Note: marketplace listings will be updated in the callback if delete confirmed
return;
}
@@ -2583,18 +2583,19 @@ void LLInventoryAction::removeItemFromDND(LLFolderView* root)
}
}
-void LLInventoryAction::onItemsRemovalConfirmation( const LLSD& notification, const LLSD& response, LLFolderView* root )
+void LLInventoryAction::onItemsRemovalConfirmation(const LLSD& notification, const LLSD& response, LLHandle<LLFolderView> root)
{
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
- if (option == 0)
+ if (option == 0 && !root.isDead() && !root.get()->isDead())
{
- //Need to remove item from DND before item is removed from root folder view
- //because once removed from root folder view the item is no longer a selected item
- removeItemFromDND(root);
- root->removeSelectedItems();
-
- // Update the marketplace listings that have been affected by the operation
- updateMarketplaceFolders();
+ LLFolderView* folder_root = root.get();
+ //Need to remove item from DND before item is removed from root folder view
+ //because once removed from root folder view the item is no longer a selected item
+ removeItemFromDND(folder_root);
+ folder_root->removeSelectedItems();
+
+ // Update the marketplace listings that have been affected by the operation
+ updateMarketplaceFolders();
}
}
@@ -2650,4 +2651,3 @@ void LLInventoryAction::updateMarketplaceFolders()
}
-