diff options
| author | Richard Linden <none@none> | 2011-11-07 11:15:40 -0800 |
|---|---|---|
| committer | Richard Linden <none@none> | 2011-11-07 11:15:40 -0800 |
| commit | 32dca99fe59196fa4a92a815b441b4e6e9f747f0 (patch) | |
| tree | 6a257d591ad0f241c7fbd42acca72ea79e4c9cf6 /indra/newview/lltoolbarview.cpp | |
| parent | 8f47f2222c207938c8fc55158a6fff64ccf1e781 (diff) | |
| parent | d6d4bfa02a46c5c7f2e5376b9fad79f2624dda83 (diff) | |
Automated merge with http://hg.secondlife.com/viewer-development
Diffstat (limited to 'indra/newview/lltoolbarview.cpp')
| -rw-r--r-- | indra/newview/lltoolbarview.cpp | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/indra/newview/lltoolbarview.cpp b/indra/newview/lltoolbarview.cpp index ed1dfbb8cd..5ff0ccfeb2 100644 --- a/indra/newview/lltoolbarview.cpp +++ b/indra/newview/lltoolbarview.cpp @@ -315,6 +315,19 @@ bool LLToolBarView::loadToolbars(bool force_default) return true; } +bool LLToolBarView::clearToolbars() +{ + for (S32 i = TOOLBAR_FIRST; i <= TOOLBAR_LAST; i++) + { + if (mToolbars[i]) + { + mToolbars[i]->clearCommandsList(); + } + } + + return true; +} + //static bool LLToolBarView::loadDefaultToolbars() { @@ -332,6 +345,23 @@ bool LLToolBarView::loadDefaultToolbars() return retval; } +//static +bool LLToolBarView::clearAllToolbars() +{ + bool retval = false; + + if (gToolBarView) + { + retval = gToolBarView->clearToolbars(); + if (retval) + { + gToolBarView->saveToolbars(); + } + } + + return retval; +} + void LLToolBarView::saveToolbars() const { if (!mToolbarsLoaded) |
