diff options
author | Merov Linden <merov@lindenlab.com> | 2012-07-19 20:38:07 -0700 |
---|---|---|
committer | Merov Linden <merov@lindenlab.com> | 2012-07-19 20:38:07 -0700 |
commit | efa73d4975afda19ee5255d5cca33fa96fc21eb4 (patch) | |
tree | 6fceea8d9359380c337d7f0f67e612bfb3dbe8be /indra/newview/llinventorymodel.cpp | |
parent | 15f6f877f923ecc85489c0159ca62deb02de1201 (diff) |
CHUI-236 : WIP : Places panel works for My Inventory but still empty lists for Favorites Bar, My Landmarks and Library.
Diffstat (limited to 'indra/newview/llinventorymodel.cpp')
-rw-r--r-- | indra/newview/llinventorymodel.cpp | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index 3250d60179..9b0d12b353 100644 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -210,7 +210,7 @@ const LLViewerInventoryCategory *LLInventoryModel::getFirstNondefaultParent(cons if (!cat) break; const LLFolderType::EType folder_type = cat->getPreferredType(); if (folder_type != LLFolderType::FT_NONE && -// folder_type != LLFolderType::FT_ROOT_INVENTORY && + folder_type != LLFolderType::FT_ROOT_INVENTORY && !LLFolderType::lookupIsEnsembleType(folder_type)) { return cat; @@ -380,12 +380,11 @@ const LLUUID LLInventoryModel::findCategoryUUIDForType(LLFolderType::EType prefe LLUUID rv = LLUUID::null; const LLUUID &root_id = (find_in_library) ? gInventory.getLibraryRootFolderID() : gInventory.getRootFolderID(); -// if(LLFolderType::FT_ROOT_INVENTORY == preferred_type) -// { -// rv = root_id; -// } -// else if (root_id.notNull()) - if (root_id.notNull()) + if(LLFolderType::FT_ROOT_INVENTORY == preferred_type) + { + rv = root_id; + } + else if (root_id.notNull()) { cat_array_t* cats = NULL; cats = get_ptr_in_map(mParentChildCategoryTree, root_id); @@ -2027,11 +2026,11 @@ void LLInventoryModel::buildParentChildMap() { cat->setParent(findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND)); } -// else if(LLFolderType::FT_ROOT_INVENTORY == pref) -// { + else if(LLFolderType::FT_ROOT_INVENTORY == pref) + { // it's the root -// cat->setParent(LLUUID::null); -// } + cat->setParent(LLUUID::null); + } else { // it's a protected folder. @@ -2161,14 +2160,14 @@ void LLInventoryModel::buildParentChildMap() if(category && category->getPreferredType() != LLFolderType::FT_ROOT_INVENTORY) continue; -// if ( category && 0 == LLStringUtil::compareInsensitive(name, category->getName()) ) -// { -// if(category->getUUID()!=mRootFolderID) -// { -// LLUUID& new_inv_root_folder_id = const_cast<LLUUID&>(mRootFolderID); -// new_inv_root_folder_id = category->getUUID(); -// } -// } + if ( category && 0 == LLStringUtil::compareInsensitive(name, category->getName()) ) + { + if(category->getUUID()!=mRootFolderID) + { + LLUUID& new_inv_root_folder_id = const_cast<LLUUID&>(mRootFolderID); + new_inv_root_folder_id = category->getUUID(); + } + } } } |