elm: Fix division by zero in elm_interface_scroller

SVN revision: 75483
This commit is contained in:
Leandro Pereira 2012-08-21 02:46:17 +00:00
parent f6b7b459fa
commit 379a494a87
1 changed files with 7 additions and 2 deletions

View File

@ -2682,8 +2682,13 @@ _elm_scroll_hold_animator(void *data)
dst_index++;
}
}
fx = xsum / dst_index;
fy = ysum / dst_index;
if (dst_index)
{
fx = xsum / dst_index;
fy = ysum / dst_index;
}
else
fx = fy = 0;
}
_elm_scroll_content_pos_get(sid->obj, &ox, &oy);