summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatersettingsdebug.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloatersettingsdebug.cpp')
-rw-r--r--indra/newview/llfloatersettingsdebug.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/newview/llfloatersettingsdebug.cpp b/indra/newview/llfloatersettingsdebug.cpp
index fb202b4c40..73269d0531 100644
--- a/indra/newview/llfloatersettingsdebug.cpp
+++ b/indra/newview/llfloatersettingsdebug.cpp
@@ -34,6 +34,7 @@
#include "llcolorswatch.h"
#include "llviewercontrol.h"
#include "lltexteditor.h"
+#include "llviewershadermgr.h"
LLFloaterSettingsDebug::LLFloaterSettingsDebug(const LLSD& key)
@@ -207,6 +208,11 @@ void LLFloaterSettingsDebug::updateControl(LLControlVariable* controlp)
getChildView("val_text")->setVisible( FALSE);
mComment->setText(LLStringUtil::null);
+ getChild<LLUICtrl>("boolean_combo")->setEnabled(true);
+ getChild<LLUICtrl>("TRUE")->setEnabled(true);
+ getChild<LLUICtrl>("FALSE")->setEnabled(true);
+ getChild<LLUICtrl>("default_btn")->setEnabled(true);
+
if (controlp)
{
eControlType type = controlp->type();
@@ -288,6 +294,19 @@ void LLFloaterSettingsDebug::updateControl(LLControlVariable* controlp)
{
getChild<LLUICtrl>("boolean_combo")->setValue(LLSD(""));
}
+
+ bool bUseVAO = controlp->getName() == "RenderUseVAO";
+ if (bUseVAO)
+ {
+ bool use_shaders = LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_OBJECT) > 0;
+ getChild<LLUICtrl>("boolean_combo")->setEnabled(use_shaders);
+ getChild<LLUICtrl>("TRUE")->setEnabled(use_shaders);
+ getChild<LLUICtrl>("FALSE")->setEnabled(use_shaders);
+ getChild<LLUICtrl>("default_btn")->setEnabled(use_shaders);
+ if (!use_shaders) {
+ getChild<LLUICtrl>("boolean_combo")->setValue(LLSD(false));
+ }
+ }
}
break;
case TYPE_STRING: