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
This commit is contained in:
2010-12-09 18:31:40 +00:00
parent 4640833747
commit 41acfb1907
2 changed files with 7 additions and 2 deletions

View File

@@ -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;

View File

@@ -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);