diff options
Diffstat (limited to 'indra/newview/lltool.cpp')
-rw-r--r-- | indra/newview/lltool.cpp | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/indra/newview/lltool.cpp b/indra/newview/lltool.cpp index 6a3ada0474..ceb1358d1c 100644 --- a/indra/newview/lltool.cpp +++ b/indra/newview/lltool.cpp @@ -65,6 +65,20 @@ LLTool::~LLTool() } } +BOOL LLTool::handleAnyMouseClick(S32 x, S32 y, MASK mask, LLMouseHandler::EClickType clicktype, BOOL down) +{ + // This is necessary to force clicks in the world to cause edit + // boxes that might have keyboard focus to relinquish it, and hence + // cause a commit to update their value. JC + if (down) + { + gFocusMgr.setKeyboardFocus(NULL); + } + + return LLMouseHandler::handleAnyMouseClick(x, y, mask, clicktype, down); +} + + BOOL LLTool::handleMouseDown(S32 x, S32 y, MASK mask) { if (gDebugClicks) @@ -91,7 +105,7 @@ BOOL LLTool::handleMouseUp(S32 x, S32 y, MASK mask) BOOL LLTool::handleHover(S32 x, S32 y, MASK mask) { - gViewerWindow->getWindow()->setCursor(UI_CURSOR_ARROW); + gViewerWindow->setCursor(UI_CURSOR_ARROW); lldebugst(LLERR_USER_INPUT) << "hover handled by a tool" << llendl; // by default, do nothing, say we handled it return TRUE; @@ -139,7 +153,7 @@ BOOL LLTool::handleMiddleMouseUp(S32 x, S32 y, MASK mask) return FALSE; } -BOOL LLTool::handleToolTip(S32 x, S32 y, std::string& msg, LLRect* sticky_rect_screen) +BOOL LLTool::handleToolTip(S32 x, S32 y, std::string& msg, LLRect& sticky_rect_screen) { // by default, didn't handle it // llinfos << "LLTool::handleToolTip" << llendl; |