summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatersearch.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloatersearch.cpp')
-rw-r--r--indra/newview/llfloatersearch.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/indra/newview/llfloatersearch.cpp b/indra/newview/llfloatersearch.cpp
index 97c573ddea..ca2cdffcf8 100644
--- a/indra/newview/llfloatersearch.cpp
+++ b/indra/newview/llfloatersearch.cpp
@@ -36,6 +36,7 @@
#include "llmediactrl.h"
#include "lllogininstance.h"
#include "lluri.h"
+#include "llagent.h"
LLFloaterSearch::LLFloaterSearch(const LLSD& key) :
LLFloater(key),
@@ -122,6 +123,12 @@ void LLFloaterSearch::search(const LLSD &key)
LLSD search_token = LLLoginInstance::getInstance()->getResponse("search_token");
url += "&p=" + search_token.asString();
+ // also append the user's preferred maturity (can be changed via prefs)
+ std::string maturity = "pg";
+ if (gAgent.prefersMature()) maturity += ",mature";
+ if (gAgent.prefersAdult()) maturity += ",adult";
+ url += "&r=" + maturity;
+
// and load the URL in the web view
mBrowser->navigateTo(url);
}