diff options
author | Leslie Linden <leslie@lindenlab.com> | 2011-06-23 18:11:55 -0400 |
---|---|---|
committer | Leslie Linden <leslie@lindenlab.com> | 2011-06-23 18:11:55 -0400 |
commit | e74f9fcc147edd24576a25bb6a0af69ac8d6a600 (patch) | |
tree | 9cfde2e6691f9d24d7a3139ff0a74d3d4e148e29 /indra/newview/llinventorypanel.cpp | |
parent | 842b6d2d142abcaa11a825a96537b0ceaef33e24 (diff) |
EXP-919 FIX -- Toggling InventoryDisplayInbox value to True in Viewer on Agni creates Inbox and Outbox system folders
* The badge no longer displays (2) when the folder does not exist.
* The inbox panel no longer displays the inventory and library folders.
* The inbox is supposed to display a string for the item not being found, but doesn't for an unknown reason.
Diffstat (limited to 'indra/newview/llinventorypanel.cpp')
-rw-r--r-- | indra/newview/llinventorypanel.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 3666c51c82..0af6451108 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -150,7 +150,10 @@ void LLInventoryPanel::buildFolderView(const LLInventoryPanel::Params& params) { // Determine the root folder in case specified, and // build the views starting with that folder. - const LLFolderType::EType preferred_type = LLViewerFolderType::lookupTypeFromNewCategoryName(params.start_folder); + + std::string start_folder_name(params.start_folder()); + + const LLFolderType::EType preferred_type = LLViewerFolderType::lookupTypeFromNewCategoryName(start_folder_name); LLUUID root_id; @@ -164,6 +167,12 @@ void LLInventoryPanel::buildFolderView(const LLInventoryPanel::Params& params) ? gInventory.findCategoryUUIDForType(preferred_type, false, false) : LLUUID::null; } + + if ((root_id == LLUUID::null) && !start_folder_name.empty()) + { + llwarns << "No category found that matches start_folder: " << start_folder_name << llendl; + root_id = LLUUID::generateNewID(); + } LLRect folder_rect(0, 0, @@ -184,7 +193,6 @@ void LLInventoryPanel::buildFolderView(const LLInventoryPanel::Params& params) p.use_label_suffix = params.use_label_suffix; p.allow_multiselect = mAllowMultiSelect; mFolderRoot = LLUICtrlFactory::create<LLFolderView>(p); - } void LLInventoryPanel::initFromParams(const LLInventoryPanel::Params& params) |