diff options
author | Loren Shih <seraph@lindenlab.com> | 2010-06-15 15:56:46 -0400 |
---|---|---|
committer | Loren Shih <seraph@lindenlab.com> | 2010-06-15 15:56:46 -0400 |
commit | 40133be7bebbf27aa8d2994e558f3b5a6706f2f9 (patch) | |
tree | 3d8640ba6358865aa63baa3449620c6335a10028 | |
parent | f8a8499c9d5b4895a96564fd3925b9becb68cbfd (diff) |
EXT-7829 FIXED Corrupted graphics in inventory side panel (gray box)
Took out ensemble folder icon use, replaced with default icons.
-rw-r--r-- | indra/newview/llviewerfoldertype.cpp | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/indra/newview/llviewerfoldertype.cpp b/indra/newview/llviewerfoldertype.cpp index 56b5d7467c..3105a6ec43 100644 --- a/indra/newview/llviewerfoldertype.cpp +++ b/indra/newview/llviewerfoldertype.cpp @@ -110,8 +110,6 @@ protected: LLViewerFolderDictionary::LLViewerFolderDictionary() { - initEnsemblesFromFile(); - // NEW CATEGORY NAME FOLDER OPEN FOLDER CLOSED QUIET? // |-------------------------|-----------------------|----------------------|-----------| addEntry(LLFolderType::FT_TEXTURE, new ViewerFolderEntry("Textures", "Inv_SysOpen", "Inv_SysClosed", FALSE)); @@ -137,6 +135,15 @@ LLViewerFolderDictionary::LLViewerFolderDictionary() addEntry(LLFolderType::FT_INBOX, new ViewerFolderEntry("Inbox", "Inv_SysOpen", "Inv_SysClosed", FALSE)); addEntry(LLFolderType::FT_NONE, new ViewerFolderEntry("New Folder", "Inv_FolderOpen", "Inv_FolderClosed", FALSE, "default")); + +#if SUPPORT_ENSEMBLES + initEnsemblesFromFile(); +#else + for (U32 type = (U32)LLFolderType::FT_ENSEMBLE_START; type <= (U32)LLFolderType::FT_ENSEMBLE_END; ++type) + { + addEntry((LLFolderType::EType)type, new ViewerFolderEntry("New Folder", "Inv_FolderOpen", "Inv_FolderClosed", FALSE)); + } +#endif } bool LLViewerFolderDictionary::initEnsemblesFromFile() @@ -231,6 +238,15 @@ const std::string &LLViewerFolderType::lookupIconName(LLFolderType::EType folder else return entry->mIconNameClosed; } + + // Error condition. Return something so that we don't show a grey box in inventory view. + const ViewerFolderEntry *default_entry = LLViewerFolderDictionary::getInstance()->lookup(LLFolderType::FT_NONE); + if (default_entry) + { + return default_entry->mIconNameClosed; + } + + // Should not get here unless there's something corrupted with the FT_NONE entry. return badLookup(); } |