diff options
| author | Lynx Linden <lynx@lindenlab.com> | 2010-01-13 11:06:50 +0000 |
|---|---|---|
| committer | Lynx Linden <lynx@lindenlab.com> | 2010-01-13 11:06:50 +0000 |
| commit | 3f07a635c877332ecd49efef4d83da1e856a4fc9 (patch) | |
| tree | b35852e3b1ab9ec70bbc6f4341ced18c63e476af /indra/newview/llviewerhome.cpp | |
| parent | abc190525fd047b22f2e50b22a9fcd4d05f45e83 (diff) | |
DEV-44861: Support a home_sidetray_url from login.cgi
The URL for the Home side tray is specified in settings.xml. It can
now be overriden on a grid-level via a "home_sidetray_url" token sent
by login.cgi.
I also updated the Home URL in settings.xml to pass through a bunch of
information to the web server as query params. These include:
p= : the authentication token from login.cgi
lang= : the user's current two-letter language setting
channel= : the viewer's channel name, e.g., "Second Life Beta",
"Second Life Release", "Snowglobe", etc.
version= : the viewer's version number, e.g., "2.0.0.200712"
major= : the viewer's major version number, e.g. "2"
minor= : the viewer's minor version number, e.g. "0"
Diffstat (limited to 'indra/newview/llviewerhome.cpp')
| -rw-r--r-- | indra/newview/llviewerhome.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/indra/newview/llviewerhome.cpp b/indra/newview/llviewerhome.cpp index 6299b4fabd..8fdbe0a4ae 100644 --- a/indra/newview/llviewerhome.cpp +++ b/indra/newview/llviewerhome.cpp @@ -50,9 +50,18 @@ std::string LLViewerHome::getHomeURL() LLSD substitution; substitution["AUTH_TOKEN"] = LLURI::escape(getAuthKey()); - // get the home URL and expand all of the substitutions - // (also adds things like [LANGUAGE], [VERSION], [OS], etc.) + // get the home URL from the settings.xml file std::string homeURL = gSavedSettings.getString("HomeSidePanelURL"); + + // support a grid-level override of the URL from login.cgi + LLSD grid_url = LLLoginInstance::getInstance()->getResponse("home_sidetray_url"); + if (! grid_url.asString().empty()) + { + homeURL = grid_url.asString(); + } + + // expand all substitution strings in the URL and return it + // (also adds things like [LANGUAGE], [VERSION], [OS], etc.) return LLWeb::expandURLSubstitutions(homeURL, substitution); } |
