diff options
| author | Richard Linden <none@none> | 2011-09-27 15:54:18 -0700 |
|---|---|---|
| committer | Richard Linden <none@none> | 2011-09-27 15:54:18 -0700 |
| commit | 9eef4b6c569b48975cd74ef80b1393febe1387d8 (patch) | |
| tree | c881f642380d37087c606f25c17129afbdf1c971 /indra/llui/lltoolbar.cpp | |
| parent | 18b3afe11a59b3fae85bc803c6afc95c8689a84b (diff) | |
| parent | 8912a9bef62386e5eecaa61ba9079d507ae16d90 (diff) | |
Automated merge with ssh://hg.lindenlab.com/richard/viewer-experience-fui
Diffstat (limited to 'indra/llui/lltoolbar.cpp')
| -rw-r--r-- | indra/llui/lltoolbar.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/indra/llui/lltoolbar.cpp b/indra/llui/lltoolbar.cpp index 8249df3e9d..677d50a0c7 100644 --- a/indra/llui/lltoolbar.cpp +++ b/indra/llui/lltoolbar.cpp @@ -30,6 +30,7 @@ #include <boost/foreach.hpp> #include "lltoolbar.h" +#include "llcommandmanager.h" #include "llmenugl.h" #include "lltrans.h" @@ -206,8 +207,8 @@ bool LLToolBar::addCommand(const LLCommandId& commandId) if (add_command) { - mButtonCommands.push_back(commandId); - createButtons(); + mButtonCommands.push_back(commandId); + createButtons(); } return add_command; @@ -251,7 +252,9 @@ bool LLToolBar::enableCommand(const LLCommandId& commandId, bool enabled) BOOL LLToolBar::handleRightMouseDown(S32 x, S32 y, MASK mask) { - BOOL handle_it_here = !mReadOnly; + LLRect button_panel_rect; + mButtonPanel->localRectToOtherView(mButtonPanel->getLocalRect(), &button_panel_rect, this); + BOOL handle_it_here = !mReadOnly && button_panel_rect.pointInRect(x, y); if (handle_it_here) { |
