summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterwater.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterwater.cpp')
-rw-r--r--indra/newview/llfloaterwater.cpp16
1 files changed, 3 insertions, 13 deletions
diff --git a/indra/newview/llfloaterwater.cpp b/indra/newview/llfloaterwater.cpp
index 85bb20a1db..533831f181 100644
--- a/indra/newview/llfloaterwater.cpp
+++ b/indra/newview/llfloaterwater.cpp
@@ -59,8 +59,6 @@
#undef max
-LLFloaterWater* LLFloaterWater::sWater = NULL;
-
std::set<std::string> LLFloaterWater::sDefaultPresets;
LLEnvKey::EScope LLFloaterWater::sScope;
std::string LLFloaterWater::sOriginalTitle;
@@ -108,19 +106,11 @@ BOOL LLFloaterWater::postBuild()
return TRUE;
}
-//static
-LLFloaterWater* LLFloaterWater::instance()
-{
- if (!sWater)
- {
- sWater = new LLFloaterWater(LLSD());
- }
- return sWater;
-}
-
+// static
void LLFloaterWater::show(LLEnvKey::EScope scope)
{
- LLFloaterWater* water = instance();
+ LLFloaterWater* water = LLFloaterReg::getTypedInstance<LLFloaterWater>("env_water");
+ llassert(water);
if(scope != sScope && ((LLView*)water)->getVisible())
{