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:
authorTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>2012-12-23 04:23:11 +0400
committerTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>2012-12-23 04:23:11 +0400
commit40449b1994301081f96d014df626a5375e020c76 (patch)
tree20220d8b071310fda8a0ab851c7a8f7bcc3ed8a2 /source/blender/editors/animation
parentfa0211df269a3398dd70467982f9e129c79e501b (diff)
parent3ca00cbf541d0283e91dc454866a5f24576271be (diff)
Merged changes in the trunk up to revision 53280.
Diffstat (limited to 'source/blender/editors/animation')
-rw-r--r--source/blender/editors/animation/anim_filter.c14
-rw-r--r--source/blender/editors/animation/fmodifier_ui.c8
2 files changed, 10 insertions, 12 deletions
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c
index 23d35c80409..37fd05f75a5 100644
--- a/source/blender/editors/animation/anim_filter.c
+++ b/source/blender/editors/animation/anim_filter.c
@@ -293,7 +293,7 @@ static short nlaedit_get_context(bAnimContext *ac, SpaceNla *snla)
short ANIM_animdata_context_getdata(bAnimContext *ac)
{
SpaceLink *sl = ac->sl;
- short ok = 0;
+ short ok = FALSE;
/* context depends on editor we are currently in */
if (sl) {
@@ -322,10 +322,7 @@ short ANIM_animdata_context_getdata(bAnimContext *ac)
}
/* check if there's any valid data */
- if (ok && ac->data)
- return 1;
- else
- return 0;
+ return (ok && ac->data);
}
/* Obtain current anim-data context from Blender Context info
@@ -357,6 +354,7 @@ short ANIM_animdata_get_context(const bContext *C, bAnimContext *ac)
ac->regiontype = (ar) ? ar->regiontype : 0;
/* get data context info */
+ // XXX: if the below fails, try to grab this info from context instead... (to allow for scripting)
return ANIM_animdata_context_getdata(ac);
}
@@ -931,14 +929,14 @@ static short skip_fcurve_selected_data(bDopeSheet *ads, FCurve *fcu, ID *owner_i
Editing *ed = BKE_sequencer_editing_get(scene, FALSE);
Sequence *seq = NULL;
char *seq_name;
-
+
if (ed) {
/* get strip name, and check if this strip is selected */
seq_name = BLI_str_quoted_substrN(fcu->rna_path, "sequences_all[");
seq = BKE_sequence_get_by_name(ed->seqbasep, seq_name, FALSE);
if (seq_name) MEM_freeN(seq_name);
}
-
+
/* can only add this F-Curve if it is selected */
if (ads->filterflag & ADS_FILTER_ONLYSEL) {
if ((seq == NULL) || (seq->flag & SELECT) == 0)
@@ -2214,7 +2212,7 @@ static size_t animdata_filter_dopesheet_scene(bAnimContext *ac, ListBase *anim_d
if ((ntree) && !(ads->filterflag & ADS_FILTER_NONTREE)) {
tmp_items += animdata_filter_ds_nodetree(ac, &tmp_data, ads, (ID *)sce, ntree, filter_mode);
}
-
+
#ifdef WITH_FREESTYLE
/* line styles */
if ((ads->filterflag & ADS_FILTER_NOLINESTYLE) == 0) {
diff --git a/source/blender/editors/animation/fmodifier_ui.c b/source/blender/editors/animation/fmodifier_ui.c
index 79a4c9a769d..6bd774e084a 100644
--- a/source/blender/editors/animation/fmodifier_ui.c
+++ b/source/blender/editors/animation/fmodifier_ui.c
@@ -151,7 +151,7 @@ static void draw_modifier__generator(uiLayout *layout, ID *id, FModifier *fcm, s
}
else {
/* basic size (just "x") */
- maxXWidth = 15;
+ maxXWidth = UI_GetStringWidth("x") + 10;
}
/* draw controls for each coefficient and a + sign at end of row */
@@ -231,16 +231,16 @@ static void draw_modifier__generator(uiLayout *layout, ID *id, FModifier *fcm, s
uiDefButF(block, NUM, B_FMODIFIER_REDRAW, "", 0, 0, 100, 20, cp + 1, -UI_FLT_MAX, UI_FLT_MAX,
10, 3, TIP_("Second coefficient"));
- /* closing bracket and '+' sign */
+ /* closing bracket and multiplication sign */
if ( (i != (data->poly_order - 1)) || ((i == 0) && data->poly_order == 2) ) {
- uiDefBut(block, LABEL, 1, ") +", 0, 0, 30, 20, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefBut(block, LABEL, 1, ") ×", 0, 0, 40, 20, NULL, 0.0, 0.0, 0, 0, "");
/* set up new row for the next pair of coefficients */
row = uiLayoutRow(layout, TRUE);
block = uiLayoutGetBlock(row);
}
else
- uiDefBut(block, LABEL, 1, ")", 0, 0, 20, 20, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefBut(block, LABEL, 1, ") ", 0, 0, 40, 20, NULL, 0.0, 0.0, 0, 0, "");
}
}
break;