fix tooltip issues in render options too
This commit is contained in:
parent
4f2d24bcff
commit
082530d18c
@ -53,6 +53,10 @@ void Checkbox::OnMouseUp(int x, int y, unsigned int button)
|
|||||||
void Checkbox::OnMouseEnter(int x, int y)
|
void Checkbox::OnMouseEnter(int x, int y)
|
||||||
{
|
{
|
||||||
isMouseOver = true;
|
isMouseOver = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Checkbox::OnMouseHover(int x, int y)
|
||||||
|
{
|
||||||
if(toolTip.length()>0 && GetParentWindow())
|
if(toolTip.length()>0 && GetParentWindow())
|
||||||
{
|
{
|
||||||
GetParentWindow()->ToolTip(this, ui::Point(x, y), toolTip);
|
GetParentWindow()->ToolTip(this, ui::Point(x, y), toolTip);
|
||||||
|
@ -25,6 +25,7 @@ public:
|
|||||||
void SetIcon(Icon icon);
|
void SetIcon(Icon icon);
|
||||||
void Draw(const Point& screenPos);
|
void Draw(const Point& screenPos);
|
||||||
virtual void OnMouseEnter(int x, int y);
|
virtual void OnMouseEnter(int x, int y);
|
||||||
|
virtual void OnMouseHover(int x, int y);
|
||||||
virtual void OnMouseLeave(int x, int y);
|
virtual void OnMouseLeave(int x, int y);
|
||||||
virtual void OnMouseClick(int x, int y, unsigned int button);
|
virtual void OnMouseClick(int x, int y, unsigned int button);
|
||||||
virtual void OnMouseUp(int x, int y, unsigned int button);
|
virtual void OnMouseUp(int x, int y, unsigned int button);
|
||||||
|
@ -394,7 +394,8 @@ void RenderView::OnKeyPress(int key, Uint16 character, bool shift, bool ctrl, bo
|
|||||||
void RenderView::ToolTip(ui::Component * sender, ui::Point mousePosition, std::string toolTip)
|
void RenderView::ToolTip(ui::Component * sender, ui::Point mousePosition, std::string toolTip)
|
||||||
{
|
{
|
||||||
this->toolTip = toolTip;
|
this->toolTip = toolTip;
|
||||||
toolTipPresence = 500;
|
if (toolTipPresence < 120)
|
||||||
|
toolTipPresence += 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
RenderView::~RenderView() {
|
RenderView::~RenderView() {
|
||||||
|
Reference in New Issue
Block a user