diff options
| author | William Todd Stinson <stinson@lindenlab.com> | 2012-11-19 12:01:51 -0800 |
|---|---|---|
| committer | William Todd Stinson <stinson@lindenlab.com> | 2012-11-19 12:01:51 -0800 |
| commit | 62301cb883dd6fadcd5d30acd604f72d2c0b1794 (patch) | |
| tree | baa94e42e64a07351c8e9722c578e94b43a811d8 /indra/llui/lluicolortable.cpp | |
| parent | 6036ee9c421154a83a306bc16533e47f9494fd32 (diff) | |
| parent | 185169cbbecebe2a35dbd937d6fb4e0a30fa1832 (diff) | |
Pull and merge from https://bitbucket.org/lindenlab/viewer-development.
Diffstat (limited to 'indra/llui/lluicolortable.cpp')
| -rw-r--r-- | indra/llui/lluicolortable.cpp | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/indra/llui/lluicolortable.cpp b/indra/llui/lluicolortable.cpp index 9455d09cc0..ffeff15968 100644 --- a/indra/llui/lluicolortable.cpp +++ b/indra/llui/lluicolortable.cpp @@ -32,6 +32,7 @@ #include "llui.h" #include "lluicolortable.h" #include "lluictrlfactory.h" +#include <boost/foreach.hpp> LLUIColorTable::ColorParams::ColorParams() : value("value"), @@ -206,19 +207,12 @@ bool LLUIColorTable::loadFromSettings() { bool result = false; - std::string default_filename = gDirUtilp->getExpandedFilename(LL_PATH_DEFAULT_SKIN, "colors.xml"); - result |= loadFromFilename(default_filename, mLoadedColors); - - std::string current_filename = gDirUtilp->getExpandedFilename(LL_PATH_TOP_SKIN, "colors.xml"); - if(current_filename != default_filename) - { - result |= loadFromFilename(current_filename, mLoadedColors); - } - - current_filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SKIN, "colors.xml"); - if(current_filename != default_filename) + // pass constraint=LLDir::ALL_SKINS because we want colors.xml from every + // skin dir + BOOST_FOREACH(std::string colors_path, + gDirUtilp->findSkinnedFilenames(LLDir::SKINBASE, "colors.xml", LLDir::ALL_SKINS)) { - result |= loadFromFilename(current_filename, mLoadedColors); + result |= loadFromFilename(colors_path, mLoadedColors); } std::string user_filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "colors.xml"); |
