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
path: root/source
diff options
context:
space:
mode:
authorJoshua Leung <aligorith@gmail.com>2011-04-05 15:04:00 +0400
committerJoshua Leung <aligorith@gmail.com>2011-04-05 15:04:00 +0400
commitbbf82877cf75bb01ce284e908bb411ae6277e55d (patch)
tree7c5b3fd321aa419f6461b8ddac2bd519ed7f34b4 /source
parent165a40e7425baa8ffe9acc2b972014c9702e84c4 (diff)
Bugfix [#26792] blender crash when scaling action strip in NLA
Two part bug: Part 1) NLA Editor menu was calling wrong operator Part 2) r35829 broke NLA scaling, since it only checked that the transform mode used was allowed in the Action Editor (probably confused by Part 1)
Diffstat (limited to 'source')
-rw-r--r--source/blender/editors/transform/transform.c6
-rw-r--r--source/blender/editors/transform/transform_conversions.c4
2 files changed, 7 insertions, 3 deletions
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c
index 43e0af53ec6..13564ffce26 100644
--- a/source/blender/editors/transform/transform.c
+++ b/source/blender/editors/transform/transform.c
@@ -5793,8 +5793,10 @@ void initTimeScale(TransInfo *t)
{
int center[2];
- /* this tool is only really available in the Action Editor... */
- if (t->spacetype != SPACE_ACTION) {
+ /* this tool is only really available in the Action Editor
+ * AND NLA Editor (for strip scaling)
+ */
+ if (ELEM(t->spacetype, SPACE_ACTION, SPACE_NLA) == 0) {
t->state = TRANS_CANCEL;
}
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c
index 99214fe4780..04783cce634 100644
--- a/source/blender/editors/transform/transform_conversions.c
+++ b/source/blender/editors/transform/transform_conversions.c
@@ -2613,6 +2613,7 @@ static void createTransNlaData(bContext *C, TransInfo *t)
unit_m3(td->smtx);
}
else {
+ /* time scaling only needs single value */
td->val= &tdn->h1[0];
td->ival= tdn->h1[0];
}
@@ -2644,6 +2645,7 @@ static void createTransNlaData(bContext *C, TransInfo *t)
unit_m3(td->smtx);
}
else {
+ /* time scaling only needs single value */
td->val= &tdn->h2[0];
td->ival= tdn->h2[0];
}
@@ -2664,7 +2666,7 @@ static void createTransNlaData(bContext *C, TransInfo *t)
}
}
}
-
+
/* cleanup temp list */
BLI_freelistN(&anim_data);
}