diff --git a/source/blender/editors/space_graph/graph_buttons.c b/source/blender/editors/space_graph/graph_buttons.c index ca8919f51a6..185bf029f1a 100644 --- a/source/blender/editors/space_graph/graph_buttons.c +++ b/source/blender/editors/space_graph/graph_buttons.c @@ -423,8 +423,25 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) col = uiLayoutColumn(layout, true); /* keyframe itself */ { + uiItemL_respect_property_split(col, IFACE_("Key Frame"), ICON_NONE); + but = uiDefButR(block, + UI_BTYPE_NUM, + B_REDR, + "", + 0, + 0, + but_max_width, + UI_UNIT_Y, + &bezt_ptr, + "co", + 0, + 0, + 0, + -1, + -1, + NULL); - uiItemL_respect_property_split(col, IFACE_("Key Value"), ICON_NONE); + uiItemL_respect_property_split(col, IFACE_("Value"), ICON_NONE); but = uiDefButR(block, UI_BTYPE_NUM, B_REDR, @@ -444,23 +461,6 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) UI_but_func_set(but, graphedit_activekey_update_cb, fcu, bezt); UI_but_unit_type_set(but, unit); - uiItemL_respect_property_split(col, IFACE_("Frame"), ICON_NONE); - but = uiDefButR(block, - UI_BTYPE_NUM, - B_REDR, - "", - 0, - 0, - but_max_width, - UI_UNIT_Y, - &bezt_ptr, - "co", - 0, - 0, - 0, - -1, - -1, - NULL); UI_but_func_set(but, graphedit_activekey_update_cb, fcu, bezt); } @@ -468,47 +468,7 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) if ((prevbezt) && (prevbezt->ipo == BEZT_IPO_BEZ)) { col = uiLayoutColumn(layout, true); - - uiItemL_respect_property_split(col, IFACE_("Left Handle X"), ICON_NONE); - but = uiDefButR(block, - UI_BTYPE_NUM, - B_REDR, - "", - 0, - 0, - but_max_width, - UI_UNIT_Y, - &bezt_ptr, - "handle_left", - 0, - 0, - 0, - -1, - -1, - NULL); - UI_but_func_set(but, graphedit_activekey_left_handle_coord_cb, fcu, bezt); - - uiItemL_respect_property_split(col, IFACE_("Y"), ICON_NONE); - but = uiDefButR(block, - UI_BTYPE_NUM, - B_REDR, - "", - 0, - 0, - but_max_width, - UI_UNIT_Y, - &bezt_ptr, - "handle_left", - 1, - 0, - 0, - -1, - -1, - NULL); - UI_but_func_set(but, graphedit_activekey_left_handle_coord_cb, fcu, bezt); - UI_but_unit_type_set(but, unit); - - uiItemL_respect_property_split(col, IFACE_("Type"), ICON_NONE); + uiItemL_respect_property_split(col, IFACE_("Left Handle Type"), ICON_NONE); but = uiDefButR(block, UI_BTYPE_MENU, B_REDR, @@ -526,6 +486,45 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) -1, "Type of left handle"); UI_but_func_set(but, graphedit_activekey_handles_cb, fcu, bezt); + + uiItemL_respect_property_split(col, IFACE_("Frame"), ICON_NONE); + but = uiDefButR(block, + UI_BTYPE_NUM, + B_REDR, + "", + 0, + 0, + but_max_width, + UI_UNIT_Y, + &bezt_ptr, + "handle_left", + 0, + 0, + 0, + -1, + -1, + NULL); + UI_but_func_set(but, graphedit_activekey_left_handle_coord_cb, fcu, bezt); + + uiItemL_respect_property_split(col, IFACE_("Value"), ICON_NONE); + but = uiDefButR(block, + UI_BTYPE_NUM, + B_REDR, + "", + 0, + 0, + but_max_width, + UI_UNIT_Y, + &bezt_ptr, + "handle_left", + 1, + 0, + 0, + -1, + -1, + NULL); + UI_but_func_set(but, graphedit_activekey_left_handle_coord_cb, fcu, bezt); + UI_but_unit_type_set(but, unit); } /* next handle - only if current is Bezier interpolation */ @@ -533,7 +532,26 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) /* NOTE: special update callbacks are needed on the coords here due to T39911 */ col = uiLayoutColumn(layout, true); - uiItemL_respect_property_split(col, IFACE_("Right Handle X"), ICON_NONE); + uiItemL_respect_property_split(col, IFACE_("Right Handle Type"), ICON_NONE); + but = uiDefButR(block, + UI_BTYPE_MENU, + B_REDR, + NULL, + 0, + 0, + but_max_width, + UI_UNIT_Y, + &bezt_ptr, + "handle_right_type", + 0, + 0, + 0, + -1, + -1, + "Type of right handle"); + UI_but_func_set(but, graphedit_activekey_handles_cb, fcu, bezt); + + uiItemL_respect_property_split(col, IFACE_("Frame"), ICON_NONE); but = uiDefButR(block, UI_BTYPE_NUM, B_REDR, @@ -552,7 +570,7 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) NULL); UI_but_func_set(but, graphedit_activekey_right_handle_coord_cb, fcu, bezt); - uiItemL_respect_property_split(col, IFACE_("Y"), ICON_NONE); + uiItemL_respect_property_split(col, IFACE_("Value"), ICON_NONE); but = uiDefButR(block, UI_BTYPE_NUM, B_REDR, @@ -571,25 +589,6 @@ static void graph_panel_key_properties(const bContext *C, Panel *panel) NULL); UI_but_func_set(but, graphedit_activekey_right_handle_coord_cb, fcu, bezt); UI_but_unit_type_set(but, unit); - - uiItemL_respect_property_split(col, IFACE_("Type"), ICON_NONE); - but = uiDefButR(block, - UI_BTYPE_MENU, - B_REDR, - NULL, - 0, - 0, - but_max_width, - UI_UNIT_Y, - &bezt_ptr, - "handle_right_type", - 0, - 0, - 0, - -1, - -1, - "Type of right handle"); - UI_but_func_set(but, graphedit_activekey_handles_cb, fcu, bezt); } } else {