diff options
author | Richard Nelson <richard@lindenlab.com> | 2011-09-30 16:58:09 -0700 |
---|---|---|
committer | Richard Nelson <richard@lindenlab.com> | 2011-09-30 16:58:09 -0700 |
commit | 0991a8a870b9cfee57a76f45f4f5ee1c5eb6d4cd (patch) | |
tree | 2c503e2bec1398185e41875b3c357e5afb126c2b /indra/llui/lltoolbarview.cpp | |
parent | 6fe4815217a11a36aa2e2b1d8b040eff007bb631 (diff) | |
parent | 09e179b2381a4db03309839babae664feb9b0886 (diff) |
Automated merge with ssh://hg.lindenlab.com/richard/viewer-experience-fui
Diffstat (limited to 'indra/llui/lltoolbarview.cpp')
-rw-r--r-- | indra/llui/lltoolbarview.cpp | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/indra/llui/lltoolbarview.cpp b/indra/llui/lltoolbarview.cpp index 12247519ad..0996577114 100644 --- a/indra/llui/lltoolbarview.cpp +++ b/indra/llui/lltoolbarview.cpp @@ -114,7 +114,7 @@ bool LLToolBarView::addCommand(const LLCommandId& command, LLToolBar* toolbar) } bool LLToolBarView::loadToolbars(bool force_default) -{ +{ LLToolBarView::ToolbarSet toolbar_set; // Load the toolbars.xml file @@ -221,19 +221,18 @@ void LLToolBarView::saveToolbars() const { // Build the parameter tree from the toolbar data LLToolBarView::ToolbarSet toolbar_set; + + // *TODO : factorize that code a bit... if (mToolbarLeft) { - toolbar_set.left_toolbar.button_display_mode = (int)(mToolbarLeft->getButtonType()); addToToolset(mToolbarLeft->getCommandsList(),toolbar_set.left_toolbar); } if (mToolbarRight) { - toolbar_set.right_toolbar.button_display_mode = (int)(mToolbarRight->getButtonType()); addToToolset(mToolbarRight->getCommandsList(),toolbar_set.right_toolbar); } if (mToolbarBottom) { - toolbar_set.bottom_toolbar.button_display_mode = (int)(mToolbarBottom->getButtonType()); addToToolset(mToolbarBottom->getCommandsList(),toolbar_set.bottom_toolbar); } @@ -256,19 +255,6 @@ void LLToolBarView::saveToolbars() const } } -// Enumerate the commands in command_list and add them as Params to the toolbar -void LLToolBarView::addToToolset(command_id_list_t& command_list, Toolbar& toolbar) const -{ - for (command_id_list_t::const_iterator it = command_list.begin(); - it != command_list.end(); - ++it) - { - LLCommandId::Params command; - command.name = it->name(); - toolbar.commands.add(command); - } -} - void LLToolBarView::draw() { static bool debug_print = true; |