list_box.h: fix ProcessMouse() zero divide

git-svn-id: svn://kolibrios.org@5829 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2015-09-13 22:11:52 +00:00
parent 79bee04258
commit c036dbd692

View File

@ -108,11 +108,14 @@ int llist::ProcessMouse(int xx, yy)
cur_y = cur_y_temp;
ret = 1;
}
cur_x_temp = xx - x / item_w;
if (cur_x_temp != cur_x) && (cur_x_temp<column_max)
{
cur_x = cur_x_temp;
ret = 1;
if (horisontal_selelection)
{
cur_x_temp = xx - x / item_w;
if (cur_x_temp != cur_x) && (cur_x_temp<column_max)
{
cur_x = cur_x_temp;
ret = 1;
}
}
}
return ret;