summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/llagent.cpp5
-rw-r--r--indra/newview/llagent.h1
-rw-r--r--indra/newview/llagentaccess.cpp12
-rw-r--r--indra/newview/llagentaccess.h1
-rw-r--r--indra/newview/llviewermenu.cpp28
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml6
-rw-r--r--indra/newview/tests/llagentaccess_test.cpp30
7 files changed, 9 insertions, 74 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 23a2908ce6..07a439e696 100755
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -2481,11 +2481,6 @@ bool LLAgent::isAdult() const
return mAgentAccess->isAdult();
}
-void LLAgent::setTeen(bool teen)
-{
- mAgentAccess->setTeen(teen);
-}
-
//static
int LLAgent::convertTextToMaturity(char text)
{
diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h
index dcb26efe41..1ca12f14b7 100644
--- a/indra/newview/llagent.h
+++ b/indra/newview/llagent.h
@@ -688,7 +688,6 @@ public:
bool isTeen() const;
bool isMature() const;
bool isAdult() const;
- void setTeen(bool teen);
void setMaturity(char text);
static int convertTextToMaturity(char text);
diff --git a/indra/newview/llagentaccess.cpp b/indra/newview/llagentaccess.cpp
index bf2a78e7f5..c4ee321e04 100644
--- a/indra/newview/llagentaccess.cpp
+++ b/indra/newview/llagentaccess.cpp
@@ -132,18 +132,6 @@ bool LLAgentAccess::isAdult() const
return mAccess >= SIM_ACCESS_ADULT;
}
-void LLAgentAccess::setTeen(bool teen)
-{
- if (teen)
- {
- mAccess = SIM_ACCESS_PG;
- }
- else
- {
- mAccess = SIM_ACCESS_MATURE;
- }
-}
-
//static
int LLAgentAccess::convertTextToMaturity(char text)
{
diff --git a/indra/newview/llagentaccess.h b/indra/newview/llagentaccess.h
index 90023d7575..4e851b0aa0 100644
--- a/indra/newview/llagentaccess.h
+++ b/indra/newview/llagentaccess.h
@@ -59,7 +59,6 @@ public:
bool isMature() const;
bool isAdult() const;
- void setTeen(bool teen);
void setMaturity(char text);
static int convertTextToMaturity(char text);
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index a5effe4f09..4da45ca29c 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -297,7 +297,6 @@ BOOL enable_buy_land(void*);
void handle_test_male(void *);
void handle_test_female(void *);
-void handle_toggle_pg(void*);
void handle_dump_attachments(void *);
void handle_dump_avatar_local_textures(void*);
void handle_debug_avatar_textures(void*);
@@ -1588,23 +1587,6 @@ class LLAdvancedTestFemale : public view_listener_t
}
};
-
-
-///////////////
-// TOGGLE PG //
-///////////////
-
-
-class LLAdvancedTogglePG : public view_listener_t
-{
- bool handleEvent(const LLSD& userdata)
- {
- handle_toggle_pg(NULL);
- return true;
- }
-};
-
-
class LLAdvancedForceParamsToDefault : public view_listener_t
{
bool handleEvent(const LLSD& userdata)
@@ -6639,15 +6621,6 @@ void handle_test_female(void*)
//gGestureList.requestResetFromServer( FALSE );
}
-void handle_toggle_pg(void*)
-{
- gAgent.setTeen( !gAgent.isTeen() );
-
- LLFloaterWorldMap::reloadIcons(NULL);
-
- llinfos << "PG status set to " << (S32)gAgent.isTeen() << llendl;
-}
-
void handle_dump_attachments(void*)
{
if(!isAgentAvatarValid()) return;
@@ -8208,7 +8181,6 @@ void initialize_menus()
view_listener_t::addMenu(new LLAdvancedTestMale(), "Advanced.TestMale");
view_listener_t::addMenu(new LLAdvancedTestFemale(), "Advanced.TestFemale");
- view_listener_t::addMenu(new LLAdvancedTogglePG(), "Advanced.TogglePG");
// Advanced > Character (toplevel)
view_listener_t::addMenu(new LLAdvancedForceParamsToDefault(), "Advanced.ForceParamsToDefault");
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index 1d11abcf73..938702775f 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -3098,12 +3098,6 @@
<menu_item_call.on_click
function="Advanced.TestFemale" />
</menu_item_call>
- <menu_item_call
- label="Toggle PG"
- name="Toggle PG">
- <menu_item_call.on_click
- function="Advanced.TogglePG" />
- </menu_item_call>
<menu_item_check
label="Allow Select Avatar"
name="Allow Select Avatar">
diff --git a/indra/newview/tests/llagentaccess_test.cpp b/indra/newview/tests/llagentaccess_test.cpp
index fbd2c7328b..0141a219c5 100644
--- a/indra/newview/tests/llagentaccess_test.cpp
+++ b/indra/newview/tests/llagentaccess_test.cpp
@@ -111,18 +111,6 @@ namespace tut
ensure("1 isMature", !aa.isMature());
ensure("1 isAdult", !aa.isAdult());
- // this is kinda bad -- setting this forces maturity to MATURE but !teen != Mature anymore
- aa.setTeen(false);
- ensure("2 isTeen", !aa.isTeen());
- ensure("2 isMature", aa.isMature());
- ensure("2 isAdult", !aa.isAdult());
-
- // have to flip it back and make sure it still works
- aa.setTeen(true);
- ensure("3 isTeen", aa.isTeen());
- ensure("3 isMature", !aa.isMature());
- ensure("3 isAdult", !aa.isAdult());
-
// check the conversion routine
ensure_equals("1 conversion", SIM_ACCESS_PG, aa.convertTextToMaturity('P'));
ensure_equals("2 conversion", SIM_ACCESS_MATURE, aa.convertTextToMaturity('M'));
@@ -131,21 +119,21 @@ namespace tut
// now try the other method of setting it - PG
aa.setMaturity('P');
- ensure("4 isTeen", aa.isTeen());
- ensure("4 isMature", !aa.isMature());
- ensure("4 isAdult", !aa.isAdult());
+ ensure("2 isTeen", aa.isTeen());
+ ensure("2 isMature", !aa.isMature());
+ ensure("2 isAdult", !aa.isAdult());
// Mature
aa.setMaturity('M');
- ensure("5 isTeen", !aa.isTeen());
- ensure("5 isMature", aa.isMature());
- ensure("5 isAdult", !aa.isAdult());
+ ensure("3 isTeen", !aa.isTeen());
+ ensure("3 isMature", aa.isMature());
+ ensure("3 isAdult", !aa.isAdult());
// Adult
aa.setMaturity('A');
- ensure("6 isTeen", !aa.isTeen());
- ensure("6 isMature", aa.isMature());
- ensure("6 isAdult", aa.isAdult());
+ ensure("4 isTeen", !aa.isTeen());
+ ensure("4 isMature", aa.isMature());
+ ensure("4 isAdult", aa.isAdult());
}