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:
authorBastien Montagne <montagne29@wanadoo.fr>2014-08-26 14:04:24 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2014-08-26 14:31:08 +0400
commit0e3fa0b7618fa86e97c5f46ae7208c082fd26eb7 (patch)
tree447fcae65fe6bf4086a79e03a82abb7a4138897b /source/blender/editors/animation/anim_markers.c
parent600248783b50ddef9b809b0d4c7abd9a9b20fda3 (diff)
Fix T41590: When scene scale is not 1.0, and units are "None," Blender assumes translations are in meters.
Turned out there were several issues in handling of scale parameter by numinput. Fixed that by factorizing more some code in common with 'usual' numbuttons eval code (new `bUnit_getScaleUnit()` helper will return valid scaled value, depending on given system and type). Now, numinput behaves as expected - using default unit amended by scale in case no unit is given (i.e. entering '20' with a scale of 0.01 will give you 20cm, and '20cm' as well!).
Diffstat (limited to 'source/blender/editors/animation/anim_markers.c')
-rw-r--r--source/blender/editors/animation/anim_markers.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c
index 3313b7038e8..7cd47fab83a 100644
--- a/source/blender/editors/animation/anim_markers.c
+++ b/source/blender/editors/animation/anim_markers.c
@@ -637,7 +637,7 @@ static void ed_marker_move_update_header(bContext *C, wmOperator *op)
}
if (hasNumInput(&mm->num)) {
- outputNumInput(&mm->num, str_offs, scene->unit.scale_length);
+ outputNumInput(&mm->num, str_offs, &scene->unit);
}
else if (use_time) {
BLI_snprintf(str_offs, sizeof(str_offs), "%.2f", FRA2TIME(offs));