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:
authorHans Goudey <h.goudey@me.com>2020-06-11 18:13:54 +0300
committerHans Goudey <h.goudey@me.com>2020-06-11 18:16:04 +0300
commitfea5097eb83593b612fd2f1dab662350d716025a (patch)
treef411e345604af819d5c853f0cfeadbe10c5c79c6 /source/blender/editors/space_nla
parentafa83b5bcec78565c49f34e10e3490c9d9951069 (diff)
UI: Drag and Drop FModifiers, Layout Updates
There are still problems - Context doesn't work in NLA editor - Lots of memory leaks for anim context. Should find a different method for getting the context that doesn't require a "free" every time. This also adds support for regions with panel categories to the list panel system, which was a simple oversight. Differential Revision: https://developer.blender.org/D7997
Diffstat (limited to 'source/blender/editors/space_nla')
-rw-r--r--source/blender/editors/space_nla/nla_buttons.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/source/blender/editors/space_nla/nla_buttons.c b/source/blender/editors/space_nla/nla_buttons.c
index 307b6d9bc21..3d48583dfc9 100644
--- a/source/blender/editors/space_nla/nla_buttons.c
+++ b/source/blender/editors/space_nla/nla_buttons.c
@@ -540,8 +540,7 @@ static void nla_panel_modifiers(const bContext *C, Panel *panel)
{
PointerRNA strip_ptr;
NlaStrip *strip;
- FModifier *fcm;
- uiLayout *col, *row;
+ uiLayout *row;
uiBlock *block;
/* check context and also validity of pointer */
@@ -569,12 +568,7 @@ static void nla_panel_modifiers(const bContext *C, Panel *panel)
uiItemO(row, "", ICON_PASTEDOWN, "NLA_OT_fmodifier_paste");
}
- /* draw each modifier */
- for (fcm = strip->modifiers.first; fcm; fcm = fcm->next) {
- col = uiLayoutColumn(panel->layout, true);
-
- ANIM_uiTemplate_fmodifier_draw(col, strip_ptr.owner_id, &strip->modifiers, fcm);
- }
+ ANIM_fmodifier_panels(C, &strip->modifiers);
}
/* ******************* general ******************************** */
@@ -658,4 +652,11 @@ void nla_buttons_register(ARegionType *art)
pt->draw = nla_panel_modifiers;
pt->poll = nla_strip_eval_panel_poll;
BLI_addtail(&art->paneltypes, pt);
+
+ ANIM_fcm_generator_panel_register(art);
+ ANIM_fcm_fn_generator_panel_register(art);
+ ANIM_fcm_noise_panel_register(art);
+ ANIM_fcm_envelope_panel_register(art);
+ ANIM_fcm_limits_panel_register(art);
+ ANIM_fcm_stepped_panel_register(art);
}