diff options
author | Ton Roosendaal <ton@blender.org> | 2010-12-09 21:31:40 +0300 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2010-12-09 21:31:40 +0300 |
commit | 41acfb1907ab59b47af794c1c8d0eb3ea82a89b8 (patch) | |
tree | 39c5e8e09254766a481e74d5e6c3ad0fe736108d | |
parent | 4640833747d0dbd0e245fc0487885060e9d08f18 (diff) |
Bugfix #25150
Graph editor: hotkeys for handles restored; they work immediate
and non modal now (menu was ugly and slow). Uses similar options
as 3d curve editing, but not toggling 'aligned'
HKEY: sets aligned
SHIFT+H: sets auto
ALT+H: sets free handle
VKEY: vector handle
-rw-r--r-- | source/blender/editors/space_graph/graph_edit.c | 1 | ||||
-rw-r--r-- | source/blender/editors/space_graph/graph_ops.c | 8 |
2 files changed, 7 insertions, 2 deletions
diff --git a/source/blender/editors/space_graph/graph_edit.c b/source/blender/editors/space_graph/graph_edit.c index c53e71365a6..a371a974be3 100644 --- a/source/blender/editors/space_graph/graph_edit.c +++ b/source/blender/editors/space_graph/graph_edit.c @@ -1433,7 +1433,6 @@ static int graphkeys_handletype_exec(bContext *C, wmOperator *op) ot->description= "Set type of handle for selected keyframes"; /* api callbacks */ - ot->invoke= WM_menu_invoke; ot->exec= graphkeys_handletype_exec; ot->poll= graphop_editable_keyframes_poll; diff --git a/source/blender/editors/space_graph/graph_ops.c b/source/blender/editors/space_graph/graph_ops.c index aa9cff71857..97595c9b904 100644 --- a/source/blender/editors/space_graph/graph_ops.c +++ b/source/blender/editors/space_graph/graph_ops.c @@ -31,6 +31,7 @@ #include "DNA_scene_types.h" +#include "DNA_anim_types.h" #include "BLI_blenlib.h" @@ -331,7 +332,12 @@ static void graphedit_keymap_keyframes (wmKeyConfig *keyconf, wmKeyMap *keymap) WM_keymap_add_item(keymap, "GRAPH_OT_snap", SKEY, KM_PRESS, KM_SHIFT, 0); WM_keymap_add_item(keymap, "GRAPH_OT_mirror", MKEY, KM_PRESS, KM_SHIFT, 0); - WM_keymap_add_item(keymap, "GRAPH_OT_handle_type", HKEY, KM_PRESS, 0, 0); + RNA_enum_set(WM_keymap_add_item(keymap, "GRAPH_OT_handle_type", HKEY, KM_PRESS, 0, 0)->ptr, "type", HD_ALIGN); + RNA_enum_set(WM_keymap_add_item(keymap, "GRAPH_OT_handle_type", HKEY, KM_PRESS, KM_SHIFT, 0)->ptr, "type", HD_AUTO); + RNA_enum_set(WM_keymap_add_item(keymap, "GRAPH_OT_handle_type", HKEY, KM_PRESS, KM_ALT, 0)->ptr, "type", HD_FREE); + RNA_enum_set(WM_keymap_add_item(keymap, "GRAPH_OT_handle_type", VKEY, KM_PRESS, 0, 0)->ptr, "type", HD_VECT); + + WM_keymap_add_item(keymap, "GRAPH_OT_interpolation_type", TKEY, KM_PRESS, KM_SHIFT, 0); WM_keymap_add_item(keymap, "GRAPH_OT_extrapolation_type", EKEY, KM_PRESS, KM_SHIFT, 0); |