diff options
| author | Leslie Linden <leslie@lindenlab.com> | 2011-10-31 15:13:25 -0700 |
|---|---|---|
| committer | Leslie Linden <leslie@lindenlab.com> | 2011-10-31 15:13:25 -0700 |
| commit | 334104ffa91d60d855408eca427da81a0d65908a (patch) | |
| tree | 757638a1b1aea3315d9bd08cb3e37f6347d45a6d /indra/newview/lltoolbarview.cpp | |
| parent | f01aa16298bf22d9882e8b690f672e20098547a6 (diff) | |
| parent | 727199e22362408f95651f495d6f29ac632e1f02 (diff) | |
Merge from viewer-experience
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) |
