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:
authorJoshua Leung <aligorith@gmail.com>2007-10-07 12:44:14 +0400
committerJoshua Leung <aligorith@gmail.com>2007-10-07 12:44:14 +0400
commitc60cc6ac85eb25903873014ea88a749542173cc9 (patch)
treeed632f39fafcd0a42a2cecacb832d4bbc059c451 /source/blender
parent8703dd9f52beccca20858042ac185fc48c3a2460 (diff)
== Anim Editor Transform ==
Restoring the 'force redraw' functionality, which is only active when the 'lock' icon on the header of the respective editor is turned on.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/src/transform.c49
-rw-r--r--source/blender/src/transform_generics.c2
2 files changed, 47 insertions, 4 deletions
diff --git a/source/blender/src/transform.c b/source/blender/src/transform.c
index a2317ba61bb..fe2dd4a359a 100644
--- a/source/blender/src/transform.c
+++ b/source/blender/src/transform.c
@@ -85,6 +85,7 @@
#include "BSE_drawipo.h"
#include "BSE_editnla_types.h" /* for NLAWIDTH */
+#include "BSE_editaction_types.h"
#include "BSE_view.h"
#include "BLI_arithb.h"
@@ -379,12 +380,54 @@ void convertDisplayNumToVec(float *num, float *vec)
static void viewRedrawForce(TransInfo *t)
{
- if(ELEM4(t->spacetype, SPACE_VIEW3D, SPACE_ACTION, SPACE_NLA, SPACE_IPO))
+ if (t->spacetype == SPACE_VIEW3D)
force_draw(0);
- else if(t->spacetype==SPACE_IMAGE) {
- if(G.sima->lock) force_draw_plus(SPACE_VIEW3D, 0);
+ else if (t->spacetype==SPACE_IMAGE) {
+ if (G.sima->lock) force_draw_plus(SPACE_VIEW3D, 0);
else force_draw(0);
}
+ else if (t->spacetype == SPACE_ACTION) {
+ if (G.saction->lock) {
+ short context= 0;
+ void *data= get_action_context(&context);
+
+ if (context == ACTCONT_ACTION)
+ force_draw_plus(SPACE_VIEW3D, 0);
+ else if (context == ACTCONT_SHAPEKEY)
+ force_draw_all(0);
+ else
+ force_draw(0);
+ }
+ else {
+ force_draw(0);
+ }
+ }
+ else if (t->spacetype == SPACE_NLA) {
+ if (G.snla->lock)
+ force_draw_all(0);
+ else
+ force_draw(0);
+ }
+ else if (t->spacetype == SPACE_IPO) {
+ /* update realtime */
+ if (G.sipo->lock) {
+ if (G.sipo->blocktype==ID_MA || G.sipo->blocktype==ID_TE)
+ force_draw_plus(SPACE_BUTS, 0);
+ else if (G.sipo->blocktype==ID_CA)
+ force_draw_plus(SPACE_VIEW3D, 0);
+ else if (G.sipo->blocktype==ID_KE)
+ force_draw_plus(SPACE_VIEW3D, 0);
+ else if (G.sipo->blocktype==ID_PO)
+ force_draw_plus(SPACE_VIEW3D, 0);
+ else if (G.sipo->blocktype==ID_OB)
+ force_draw_plus(SPACE_VIEW3D, 0);
+ else
+ force_draw(0);
+ }
+ else {
+ force_draw(0);
+ }
+ }
}
static void viewRedrawPost(TransInfo *t)
diff --git a/source/blender/src/transform_generics.c b/source/blender/src/transform_generics.c
index cb5b2d057c5..744933088c8 100644
--- a/source/blender/src/transform_generics.c
+++ b/source/blender/src/transform_generics.c
@@ -276,7 +276,7 @@ void recalcData(TransInfo *t)
if (ISPOIN(ei, flag & IPO_VISIBLE, icu)) {
/* watch it: if the time is wrong: do not correct handles */
- if (test_time_ipocurve(ei->icu) ) dosort++;
+ if (test_time_ipocurve(ei->icu)) dosort++;
else testhandles_ipocurve(ei->icu);
}
}