diff options
author | Sergei Litovchuk <slitovchuk@productengine.com> | 2010-01-18 20:13:48 +0200 |
---|---|---|
committer | Sergei Litovchuk <slitovchuk@productengine.com> | 2010-01-18 20:13:48 +0200 |
commit | a5dfdf0c6f64d40dc8d3d61434427471dbcfc0b2 (patch) | |
tree | 0eacde6a79fa3cbff81d52519b15655513de20ea /indra/newview/llsidetray.cpp | |
parent | 48123c536c8ae182b39440163d7002a07d126e0c (diff) |
Refactored fix for (EXT-4156) [BSI] Friendslist doesn't toggle open/close on shortcut
- Moved side panel toggling from viewer menu to side tray class.
--HG--
branch : product-engine
Diffstat (limited to 'indra/newview/llsidetray.cpp')
-rw-r--r-- | indra/newview/llsidetray.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/llsidetray.cpp b/indra/newview/llsidetray.cpp index fb8aa39445..50c47e293e 100644 --- a/indra/newview/llsidetray.cpp +++ b/indra/newview/llsidetray.cpp @@ -639,6 +639,21 @@ LLPanel* LLSideTray::showPanel (const std::string& panel_name, const LLSD& para return NULL; } +void LLSideTray::togglePanel(LLPanel* &sub_panel, const std::string& panel_name, const LLSD& params) +{ + if(!sub_panel) + return; + + if (sub_panel->isInVisibleChain()) + { + LLSideTray::getInstance()->collapseSideBar(); + } + else + { + LLSideTray::getInstance()->showPanel(panel_name, params); + } +} + // This is just LLView::findChildView specialized to restrict the search to LLPanels. // Optimization for EXT-4068 to avoid searching down to the individual item level // when inventories are large. |