diff options
| author | callum <none@none> | 2012-06-29 10:36:04 -0700 |
|---|---|---|
| committer | callum <none@none> | 2012-06-29 10:36:04 -0700 |
| commit | 11686a0917c7e6e67920aca46ade4624c5027c0e (patch) | |
| tree | 69f56b63cf711b6aef97e0b06d981e5c8087375a /indra/newview/llviewerregion.cpp | |
| parent | fd4708c2c4f221d9f2029072f786e169e119ba1a (diff) | |
| parent | 326634e1bf9b87e9c9311b67539abb43323bd33c (diff) | |
Merge with viewer-beta
Diffstat (limited to 'indra/newview/llviewerregion.cpp')
| -rw-r--r-- | indra/newview/llviewerregion.cpp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index e3cb985ddb..f3771e93d9 100644 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -655,6 +655,31 @@ std::string LLViewerRegion::accessToShortString(U8 sim_access) } // static +U8 LLViewerRegion::shortStringToAccess(const std::string &sim_access) +{ + U8 accessValue; + + if (LLStringUtil::compareStrings(sim_access, "PG") == 0) + { + accessValue = SIM_ACCESS_PG; + } + else if (LLStringUtil::compareStrings(sim_access, "M") == 0) + { + accessValue = SIM_ACCESS_MATURE; + } + else if (LLStringUtil::compareStrings(sim_access, "A") == 0) + { + accessValue = SIM_ACCESS_ADULT; + } + else + { + accessValue = SIM_ACCESS_MIN; + } + + return accessValue; +} + +// static void LLViewerRegion::processRegionInfo(LLMessageSystem* msg, void**) { // send it to 'observers' |
