summaryrefslogtreecommitdiff
path: root/indra/newview/llselectmgr.cpp
diff options
context:
space:
mode:
authorJosh Bell <josh@lindenlab.com>2007-06-04 18:46:59 +0000
committerJosh Bell <josh@lindenlab.com>2007-06-04 18:46:59 +0000
commite61a10ec5b6b84fcb5c27e8e308022d0094f8736 (patch)
treebcf6152629edb1b2548af039bd89b6b573e1e514 /indra/newview/llselectmgr.cpp
parent3e9872a297c3cf3f929e688e0e89a78f6bc050f5 (diff)
svn merge -r 62602:62831 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance --> release
Diffstat (limited to 'indra/newview/llselectmgr.cpp')
-rw-r--r--indra/newview/llselectmgr.cpp20
1 files changed, 16 insertions, 4 deletions
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index 98f842902d..6698ee7505 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -101,7 +101,7 @@ LLColor4 LLSelectMgr::sHighlightParentColor;
LLColor4 LLSelectMgr::sHighlightChildColor;
LLColor4 LLSelectMgr::sContextSilhouetteColor;
-static LLObjectSelection* get_null_object_selection();
+static LLObjectSelection *get_null_object_selection();
template<>
const LLHandle<LLObjectSelection>::NullFunc
LLHandle<LLObjectSelection>::sNullFunc = get_null_object_selection;
@@ -125,14 +125,26 @@ struct LLDeRezInfo
//
+static LLPointer<LLObjectSelection> sNullSelection;
+
//
// Functions
//
-LLObjectSelection* get_null_object_selection()
+void LLSelectMgr::cleanupGlobals()
+{
+ delete gSelectMgr;
+ gSelectMgr = NULL;
+ sNullSelection = NULL;
+}
+
+LLObjectSelection *get_null_object_selection()
{
- static LLObjectSelection null_selection;
- return &null_selection;;
+ if (sNullSelection.isNull())
+ {
+ sNullSelection = new LLObjectSelection;
+ }
+ return sNullSelection;
}