[UI] Let clickable link name boxes and name editors have hand cursors instead of I-beams.

This commit is contained in:
Router Gray
2019-10-24 20:38:33 -05:00
committed by Liru Færs
parent 2e52fe64b8
commit 7e8ebdb852
4 changed files with 26 additions and 0 deletions

View File

@@ -36,6 +36,7 @@
#include "llmenugl.h"
#include "lluictrlfactory.h"
#include "llwindow.h"
static LLRegisterWidget<LLNameEditor> r("name_editor");
@@ -90,6 +91,17 @@ BOOL LLNameEditor::handleRightMouseDown(S32 x, S32 y, MASK mask)
return LLLineEditor::handleRightMouseDown(x, y, mask);
}
// virtual
BOOL LLNameEditor::handleHover(S32 x, S32 y, MASK mask)
{
if (mAllowInteract)
{
getWindow()->setCursor(UI_CURSOR_HAND);
return true;
}
return LLLineEditor::handleHover(x, y, mask);
}
void LLNameEditor::displayAsLink(bool link)
{
static const LLUICachedControl<LLColor4> color("HTMLAgentColor");