Cleanup: warnings (clang)
[blender.git] / source / blender / editors / gpencil / annotate_paint.c
index a868e98e3dda07b7c81ca4c1dd4888b862edc87d..b6f81c818239983f98385e369572453f23c0d07b 100644 (file)
@@ -1697,8 +1697,8 @@ static void gpencil_draw_apply_event(wmOperator *op, const wmEvent *event, Depsg
        /* verify key status for straight lines */
        if ((event->ctrl > 0) || (event->alt > 0)) {
                if (p->straight[0] == 0) {
-                       int dx = abs(p->mval[0] - p->mvalo[0]);
-                       int dy = abs(p->mval[1] - p->mvalo[1]);
+                       int dx = abs((int)(p->mval[0] - p->mvalo[0]));
+                       int dy = abs((int)(p->mval[1] - p->mvalo[1]));
                        if ((dx > 0) || (dy > 0)) {
                                /* check mouse direction to replace the other coordinate with previous values */
                                if (dx >= dy) {