HTMLv: fix links hover

git-svn-id: svn://kolibrios.org@4492 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2014-01-19 22:55:57 +00:00
parent f60d20d830
commit e50945c8bc
2 changed files with 5 additions and 5 deletions

View File

@ -51,12 +51,12 @@ void LinksArray::Clear()
active = -1; active = -1;
} }
void LinksArray::Hover(dword mx, my, link_col_in, link_col_a) void LinksArray::Hover(dword mx, my, link_col_in, link_col_a, bg_col)
{ {
int i; int i;
if (active>=0) if (active>=0)
{ {
WriteText(links[active].x,links[active].y, 0x80, link_col_in, links[active].text); //WriteText(links[active].x,links[active].y, 0x80, link_col_in, links[active].text);
DrawBar(links[active].x,links[active].y+8,links[active].w,1, link_col_in); DrawBar(links[active].x,links[active].y+8,links[active].w,1, link_col_in);
active = -1; active = -1;
} }
@ -64,8 +64,8 @@ void LinksArray::Hover(dword mx, my, link_col_in, link_col_a)
{ {
if (mx>links[i].x) && (my>links[i].y) && (mx<links[i].x+links[i].w) && (my<links[i].y+links[i].h) if (mx>links[i].x) && (my>links[i].y) && (mx<links[i].x+links[i].w) && (my<links[i].y+links[i].h)
{ {
WriteText(links[i].x,links[i].y, 0x80, link_col_a, links[i].text); //WriteText(links[i].x,links[i].y, 0x80, link_col_a, links[i].text);
DrawBar(links[i].x,links[i].y+8,links[i].w,1, link_col_a); DrawBar(links[i].x,links[i].y+8,links[i].w,1, bg_col);
active = i; active = i;
return; return;
} }

View File

@ -91,7 +91,7 @@ void main()
edit_box_mouse stdcall (#address_box); edit_box_mouse stdcall (#address_box);
m.get(); m.get();
PageLinks.Hover(m.x, m.y, link_color_inactive, link_color_active); PageLinks.Hover(m.x, m.y, link_color_inactive, link_color_active, bg_color);
if (m.y>WB1.list.y) && (m.y<Form.height) && (filesize) if (m.y>WB1.list.y) && (m.y<Form.height) && (filesize)
{ {