Graph Editor Selection Fix for Durian:

Animators were having trouble selecting keyframes and their handles when zoomed in extremely. This commit seems to fix these issues, which appear to have resulted from some overflowing ints, which gave out-of-view handles priority quite often.
This commit is contained in:
Joshua Leung
2010-05-22 04:54:34 +00:00
parent db6a7280ce
commit 63db7c6116

View File

@@ -780,7 +780,7 @@ static void nearest_fcurve_vert_store (ListBase *matches, View2D *v2d, FCurve *f
* needed to access the relevant vertex coordinates in the 3x3
* 'vec' matrix
*/
UI_view2d_to_region_no_clip(v2d, bezt->vec[hpoint+1][0], bezt->vec[hpoint+1][1], &screen_co[0], &screen_co[1]);
UI_view2d_view_to_region(v2d, bezt->vec[hpoint+1][0], bezt->vec[hpoint+1][1], &screen_co[0], &screen_co[1]);
/* check if distance from mouse cursor to vert in screen space is within tolerance */
// XXX: inlined distance calculation, since we cannot do this on ints using the math lib...