GP: Use only selected points to calc transform center
authorAntonioya <blendergit@gmail.com>
Thu, 20 Dec 2018 20:25:29 +0000 (21:25 +0100)
committerAntonioya <blendergit@gmail.com>
Thu, 20 Dec 2018 20:25:29 +0000 (21:25 +0100)
source/blender/editors/transform/transform_conversions.c

index 0ac82e0f775bc6fe6421791ab6feac7d1a20a347..a2c8e173585529f17393bebc92514a4c1be46849 100644 (file)
@@ -8213,15 +8213,7 @@ static void createTransGPencil_center_get(
        zero_v3(r_center);
        int tot_sel = 0;
        for (i = 0, pt = gps->points; i < gps->totpoints; i++, pt++) {
-               bool point_ok;
-               if (is_prop_edit) {
-                       point_ok = true;
-               }
-               else {
-                       /* Only selected points in selected strokes */
-                       point_ok = (pt->flag & GP_SPOINT_SELECT) != 0;
-               }
-               if (point_ok) {
+               if (pt->flag & GP_SPOINT_SELECT) {
                        add_v3_v3(r_center, &pt->x);
                        tot_sel++;
                }