diff options
author | Mike Antipov <mantipov@productengine.com> | 2009-11-03 17:40:26 +0200 |
---|---|---|
committer | Mike Antipov <mantipov@productengine.com> | 2009-11-03 17:40:26 +0200 |
commit | 3483f9e0d04f7a956921b9ac60e85b4371f97322 (patch) | |
tree | 0a3e0df4f828cc9a6522d9843416bfa3274edf7d /indra | |
parent | 506f1787a5e3c98c60e10a00e6197303d28eb03a (diff) |
Fixed major bug EXT-2098 (Unable to delete landmarks)
The reason of this bug is that moved (removed to trash) Inventory Item exists in Panel which has no Trash folder
in View hierarchy (Favorites & Landmarks accordions).
I have updated LLInventoryPanel::modelChanged for case Inventory structure is changed:
- added condition to verify if moved item is in Inventory Panel having content of some Inventory Folder
and is not moved into the same folder. In this case appropriate View is removed from the Panel hierarchy.
--HG--
branch : product-engine
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llfloaterinventory.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/indra/newview/llfloaterinventory.cpp b/indra/newview/llfloaterinventory.cpp index a47916b7d7..274c2234de 100644 --- a/indra/newview/llfloaterinventory.cpp +++ b/indra/newview/llfloaterinventory.cpp @@ -1447,6 +1447,19 @@ void LLInventoryPanel::modelChanged(U32 mask) view_item->getParentFolder()->extractItem(view_item); view_item->addToFolder(new_parent, mFolders); } +/* + on the other side in case Inventory Panel has content of the any folder + it is possible that item moved to some folder which is absent in current + Panel. For ex. removing item (via moving to trash). + In this case we need to check if new parent is other then inventory start folder + and simply remove its View from the hierarchy. + See details in EXT-2098. +*/ + // So, let check if item was moved into folder out of this Inventory Panel. + else if (mStartFolderID.notNull() && NULL == new_parent && model_item->getParentUUID() != mStartFolderID) + { + view_item->getParentFolder()->extractItem(view_item); + } } } else |