diff options
author | Wayde Moss <wbmoss_dev@yahoo.com> | 2020-11-12 13:53:12 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@blender.org> | 2020-11-12 14:02:49 +0300 |
commit | dbbfba942867d907706222e3b0094cb18f517352 (patch) | |
tree | 624a6683bb3c1a746a6c65b4ebc1d07a454d2e69 /source/blender/editors | |
parent | 9067cd64a5083c214fd37fd65bea374312abad10 (diff) |
Fix T81813: Keyframe handles don't follow keyframes
Add a new property `co_ui` to Keyframes, the modification of which will
apply to the keyframe itself as well as its Bézier handles.
Dragging the "Keyframe" slider in the properties panel now maintains the
deltas between the keyframe and its handles, just like moving the key in
the graph editor would.
Reviewed by @sybren in T81813.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_graph/graph_buttons.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source/blender/editors/space_graph/graph_buttons.c b/source/blender/editors/space_graph/graph_buttons.c index a491ce29bd4..3a4e1883cee 100644 --- a/source/blender/editors/space_graph/graph_buttons.c +++ b/source/blender/editors/space_graph/graph_buttons.c @@ -423,13 +423,14 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) but_max_width, UI_UNIT_Y, &bezt_ptr, - "co", + "co_ui", 0, 0, 0, 0, 0, NULL); + UI_but_func_set(but, graphedit_activekey_update_cb, fcu, bezt); uiItemL_respect_property_split(col, IFACE_("Value"), ICON_NONE); but = uiDefButR(block, @@ -441,7 +442,7 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) but_max_width, UI_UNIT_Y, &bezt_ptr, - "co", + "co_ui", 1, 0, 0, @@ -450,8 +451,6 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) NULL); UI_but_func_set(but, graphedit_activekey_update_cb, fcu, bezt); UI_but_unit_type_set(but, unit); - - UI_but_func_set(but, graphedit_activekey_update_cb, fcu, bezt); } /* previous handle - only if previous was Bezier interpolation */ |