summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelvolume.cpp
diff options
context:
space:
mode:
authorsimon@lindenlab.com <simon@lindenlab.com>2011-06-21 09:36:31 -0700
committersimon@lindenlab.com <simon@lindenlab.com>2011-06-21 09:36:31 -0700
commitd11cabc4898a7a1995ed7c89d2cdac46dfcf24ec (patch)
tree9f8e5e57d4ed074e148227c56556bcace90e2e3a /indra/newview/llpanelvolume.cpp
parentc0c0a2b9a5f41fc06619330a81c34955a39ddfe2 (diff)
parentede3b577d8cebd5065514bb485e2cbd93dd5b05a (diff)
Merge with latest lindenlab/viewer-development
Diffstat (limited to 'indra/newview/llpanelvolume.cpp')
-rw-r--r--indra/newview/llpanelvolume.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/indra/newview/llpanelvolume.cpp b/indra/newview/llpanelvolume.cpp
index 7839cdd811..bb87601d20 100644
--- a/indra/newview/llpanelvolume.cpp
+++ b/indra/newview/llpanelvolume.cpp
@@ -530,17 +530,24 @@ void LLPanelVolume::refresh()
getChildView("Light Ambiance")->setVisible( visible);
getChildView("light texture control")->setVisible( visible);
- bool enable_mesh = gSavedSettings.getBOOL("MeshEnabled") &&
- gAgent.getRegion() &&
- !gAgent.getRegion()->getCapability("GetMesh").empty() &&
- !gAgent.getRegion()->getCapability("ObjectAdd").empty();
+ bool enable_mesh = false;
+ LLSD sim_features;
+ LLViewerRegion *region = gAgent.getRegion();
+ if(region)
+ {
+ LLSD sim_features;
+ region->getSimulatorFeatures(sim_features);
+ enable_mesh = sim_features.has("PhysicsShapeTypes");
+ }
getChildView("label physicsshapetype")->setVisible(enable_mesh);
getChildView("Physics Shape Type Combo Ctrl")->setVisible(enable_mesh);
getChildView("Physics Gravity")->setVisible(enable_mesh);
getChildView("Physics Friction")->setVisible(enable_mesh);
getChildView("Physics Density")->setVisible(enable_mesh);
getChildView("Physics Restitution")->setVisible(enable_mesh);
+
+ /* TODO: add/remove individual physics shape types as per the PhysicsShapeTypes simulator features */
}