diff options
author | Richard Linden <none@none> | 2010-09-17 23:12:13 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2010-09-17 23:12:13 -0700 |
commit | 325991a002894011b1da8dd54b16b4cb15f77554 (patch) | |
tree | 96d0412fe46eb0011f1481a7b84a964cfa86a094 /indra/newview/llhints.cpp | |
parent | 2deaa895de081982f4191db0810aa470da5348a2 (diff) |
EXP-60 Hints not showing after Re-enabling Hints in same session
Diffstat (limited to 'indra/newview/llhints.cpp')
-rw-r--r-- | indra/newview/llhints.cpp | 38 |
1 files changed, 18 insertions, 20 deletions
diff --git a/indra/newview/llhints.cpp b/indra/newview/llhints.cpp index bb8f4a995b..393aa188e1 100644 --- a/indra/newview/llhints.cpp +++ b/indra/newview/llhints.cpp @@ -346,26 +346,6 @@ void LLHints::hide(LLNotificationPtr hint) } //static -void LLHints::hideAll() -{ - std::vector<LLNotificationPtr> notifications; - for (hint_map_t::iterator it = sHints.begin(), end_it = sHints.end(); - it != end_it; - ++it) - { - notifications.push_back(it->first); - } - - for(std::vector<LLNotificationPtr>::iterator it = notifications.begin(), end_it = notifications.end(); - it != end_it; - ++it) - { - hide(*it); - } - -} - -//static void LLHints::registerHintTarget(const std::string& name, LLHandle<LLView> target) { sTargetRegistry.defaultRegistrar().replace(name, target); @@ -384,3 +364,21 @@ LLHandle<LLView> LLHints::getHintTarget(const std::string& name) return LLHandle<LLView>(); } } + +//static +void LLHints::initClass() +{ + sRegister.reference(); + + LLControlVariablePtr control = gSavedSettings.getControl("EnableUIHints"); + control->getSignal()->connect(boost::bind(&showHints, _2)); + gViewerWindow->getHintHolder()->setVisible(control->getValue().asBoolean()); + +} + +//staic +void LLHints::showHints(const LLSD& show) +{ + bool visible = show.asBoolean(); + gViewerWindow->getHintHolder()->setVisible(visible); +}
\ No newline at end of file |