summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/llui/llview.cpp10
-rw-r--r--indra/llui/llview.h2
-rw-r--r--indra/newview/llfloaterregioninfo.cpp8
-rwxr-xr-xindra/newview/llviewerregion.cpp4
4 files changed, 16 insertions, 8 deletions
diff --git a/indra/llui/llview.cpp b/indra/llui/llview.cpp
index 28283964e2..441b7d6a6c 100644
--- a/indra/llui/llview.cpp
+++ b/indra/llui/llview.cpp
@@ -591,12 +591,20 @@ void LLView::deleteAllChildren()
updateBoundingRect();
}
-void LLView::setAllChildrenEnabled(bool b)
+void LLView::setAllChildrenEnabled(bool b, bool recursive /*= false*/)
{
for (LLView* viewp : mChildList)
{
viewp->setEnabled(b);
}
+
+ if (recursive)
+ {
+ for (LLView* viewp : mChildList)
+ {
+ viewp->setAllChildrenEnabled(b, recursive);
+ }
+ }
}
// virtual
diff --git a/indra/llui/llview.h b/indra/llui/llview.h
index 3af748dda6..3ce7243370 100644
--- a/indra/llui/llview.h
+++ b/indra/llui/llview.h
@@ -287,7 +287,7 @@ public:
// children, etc.
virtual void deleteAllChildren();
- void setAllChildrenEnabled(bool b);
+ void setAllChildrenEnabled(bool b, bool recursive = false);
virtual void setVisible(bool visible);
void setVisibleDirect(bool visible) { mVisible = visible; }
diff --git a/indra/newview/llfloaterregioninfo.cpp b/indra/newview/llfloaterregioninfo.cpp
index 073cef3d73..931b2bd695 100644
--- a/indra/newview/llfloaterregioninfo.cpp
+++ b/indra/newview/llfloaterregioninfo.cpp
@@ -356,7 +356,7 @@ void LLFloaterRegionInfo::requestRegionInfo()
{
tab->getChild<LLPanel>("General")->setCtrlsEnabled(false);
tab->getChild<LLPanel>("Debug")->setCtrlsEnabled(false);
- tab->getChild<LLPanel>("Terrain")->setCtrlsEnabled(false);
+ tab->getChild<LLPanel>("Terrain")->setAllChildrenEnabled(false, true);
tab->getChild<LLPanel>("Estate")->setCtrlsEnabled(false);
tab->getChild<LLPanel>("Access")->setCtrlsEnabled(false);
}
@@ -553,7 +553,7 @@ void LLFloaterRegionInfo::processRegionInfo(LLMessageSystem* msg)
panel->getChild<LLUICtrl>("terrain_raise_spin")->setValue(region_info.mTerrainRaiseLimit);
panel->getChild<LLUICtrl>("terrain_lower_spin")->setValue(region_info.mTerrainLowerLimit);
- panel->setCtrlsEnabled(allow_modify);
+ panel->setAllChildrenEnabled(allow_modify, true);
if (floater->getVisible())
{
@@ -668,7 +668,7 @@ void LLFloaterRegionInfo::disableTabCtrls()
tab->getChild<LLPanel>("General")->setCtrlsEnabled(false);
tab->getChild<LLPanel>("Debug")->setCtrlsEnabled(false);
- tab->getChild<LLPanel>("Terrain")->setCtrlsEnabled(false);
+ tab->getChild<LLPanel>("Terrain")->setAllChildrenEnabled(false, true);
tab->getChild<LLPanel>("panel_env_info")->setCtrlsEnabled(false);
tab->getChild<LLPanel>("Estate")->setCtrlsEnabled(false);
tab->getChild<LLPanel>("Access")->setCtrlsEnabled(false);
@@ -1657,7 +1657,7 @@ bool LLPanelRegionTerrainInfo::refreshFromRegion(LLViewerRegion* region)
|| (region && (region->getOwner() == gAgent.getID()));
bool owner_or_god_or_manager = owner_or_god
|| (region && region->isEstateManager());
- setCtrlsEnabled(owner_or_god_or_manager);
+ setAllChildrenEnabled(owner_or_god_or_manager, true);
getChildView("apply_btn")->setEnabled(false);
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp
index c75d590df8..e8a9f41855 100755
--- a/indra/newview/llviewerregion.cpp
+++ b/indra/newview/llviewerregion.cpp
@@ -2495,11 +2495,11 @@ void LLViewerRegion::setSimulatorFeatures(const LLSD& sim_features)
if (features.has("PBRTerrainTransformsEnabled"))
{
bool enabled = features["PBRTerrainTransformsEnabled"];
- gSavedSettings.setBOOL("RenderTerrainTransformsPBREnabled", enabled);
+ gSavedSettings.setBOOL("RenderTerrainPBRTransformsEnabled", enabled);
}
else
{
- gSavedSettings.setBOOL("RenderTerrainTransformsPBREnabled", false);
+ gSavedSettings.setBOOL("RenderTerrainPBRTransformsEnabled", false);
}
};