Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-07-21 14:34:08 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-07-21 14:36:10 +0300
commitbafe22e8cea78991e3f8e4e435985f9a27a1587f (patch)
treeab718643b525946d91797dff1c1ce9d595241b57 /source/blender/editors
parent6778ef4dcc6e8d92e3b2ec9b9ecaf1e54e5bf7b5 (diff)
Fix T79112: Redo shrink/fatten uses negative values
The numbers in the redo panel were negated compared to the value entered while transforming.
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/transform/transform_input.c8
-rw-r--r--source/blender/editors/transform/transform_mode_shrink_fatten.c4
2 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/editors/transform/transform_input.c b/source/blender/editors/transform/transform_input.c
index 078020e932e..9c8d99d0d24 100644
--- a/source/blender/editors/transform/transform_input.c
+++ b/source/blender/editors/transform/transform_input.c
@@ -124,8 +124,8 @@ static void InputVerticalRatio(TransInfo *t, MouseInput *mi, const double mval[2
{
const int winy = t->region ? t->region->winy : 1;
- /* Flip so dragging up increases (matching viewport zoom). */
- output[0] = ((mval[1] - mi->imval[1]) / winy) * -2.0f;
+ /* Dragging up increases (matching viewport zoom). */
+ output[0] = ((mval[1] - mi->imval[1]) / winy) * 2.0f;
}
/** Callback for #INPUT_VERTICAL_ABSOLUTE */
@@ -139,8 +139,8 @@ static void InputVerticalAbsolute(TransInfo *t,
InputVector(t, mi, mval, vec);
project_v3_v3v3(vec, vec, t->viewinv[1]);
- /* Flip so dragging up increases (matching viewport zoom). */
- output[0] = dot_v3v3(t->viewinv[1], vec) * -2.0f;
+ /* Dragging up increases (matching viewport zoom). */
+ output[0] = dot_v3v3(t->viewinv[1], vec) * 2.0f;
}
/** Callback for #INPUT_CUSTOM_RATIO_FLIP */
diff --git a/source/blender/editors/transform/transform_mode_shrink_fatten.c b/source/blender/editors/transform/transform_mode_shrink_fatten.c
index 78d3efa0d69..6302bc96330 100644
--- a/source/blender/editors/transform/transform_mode_shrink_fatten.c
+++ b/source/blender/editors/transform/transform_mode_shrink_fatten.c
@@ -54,13 +54,13 @@ static void applyShrinkFatten(TransInfo *t, const int UNUSED(mval[2]))
char str[UI_MAX_DRAW_STR];
size_t ofs = 0;
- distance = -t->values[0];
+ distance = t->values[0];
snapGridIncrement(t, &distance);
applyNumInput(&t->num, &distance);
- t->values_final[0] = -distance;
+ t->values_final[0] = distance;
/* header print for NumInput */
ofs += BLI_strncpy_rlen(str + ofs, TIP_("Shrink/Fatten:"), sizeof(str) - ofs);