summaryrefslogtreecommitdiff
path: root/indra/newview/llselectmgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llselectmgr.cpp')
-rw-r--r--indra/newview/llselectmgr.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index f602dee0cb..690b9562a8 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -250,6 +250,23 @@ LLSelectMgr::LLSelectMgr()
mForceSelection = FALSE;
mShowSelection = FALSE;
+
+ LLControlVariable* ctrl = gSavedSettings.getControl("DebugSelectionLODs").get();
+ if (ctrl)
+ {
+ mSlectionLodModChangedConnection = ctrl->getSignal()->connect([this](LLControlVariable*, const LLSD&, const LLSD&)
+ {
+ for (LLObjectSelection::iterator iter = mSelectedObjects->begin();
+ iter != mSelectedObjects->end(); ++iter)
+ {
+ LLViewerObject* object = (*iter)->getObject();
+ if (object)
+ {
+ object->updateLOD();
+ }
+ }
+ });
+ }
}
@@ -259,6 +276,7 @@ LLSelectMgr::LLSelectMgr()
LLSelectMgr::~LLSelectMgr()
{
clearSelections();
+ mSlectionLodModChangedConnection.disconnect();
}
void LLSelectMgr::clearSelections()