expand ui events to contain semantic 'controls' info, to eliminate most hardcoded escs/returns/f2s/etc; formalize these things as proper commands; keyboard-driven expansions; other various fixes

This commit is contained in:
Ryan Fleury
2024-05-15 10:53:26 -07:00
parent 03844d81d2
commit f1af166fd4
11 changed files with 171 additions and 41 deletions
+4 -1
View File
@@ -598,7 +598,7 @@ str8_lit_comp("goto_name"),
str8_lit_comp("function_breakpoint"),
};
DF_StringBindingPair df_g_default_binding_table[99] =
DF_StringBindingPair df_g_default_binding_table[102] =
{
{str8_lit_comp("kill_all"), {OS_Key_F5, 0 |OS_EventFlag_Shift }},
{str8_lit_comp("step_into_inst"), {OS_Key_F11, 0 |OS_EventFlag_Alt}},
@@ -644,6 +644,9 @@ DF_StringBindingPair df_g_default_binding_table[99] =
{str8_lit_comp("switch_to_partner_file"), {OS_Key_O, 0 |OS_EventFlag_Alt}},
{str8_lit_comp("load_user"), {OS_Key_O, 0 |OS_EventFlag_Ctrl |OS_EventFlag_Shift |OS_EventFlag_Alt}},
{str8_lit_comp("load_profile"), {OS_Key_O, 0 |OS_EventFlag_Ctrl |OS_EventFlag_Alt}},
{str8_lit_comp("edit"), {OS_Key_F2, 0 }},
{str8_lit_comp("accept"), {OS_Key_Return, 0 }},
{str8_lit_comp("cancel"), {OS_Key_Esc, 0 }},
{str8_lit_comp("move_left"), {OS_Key_Left, 0 }},
{str8_lit_comp("move_right"), {OS_Key_Right, 0 }},
{str8_lit_comp("move_up"), {OS_Key_Up, 0 }},
+1 -1
View File
@@ -290,7 +290,7 @@ extern Vec4F32* df_g_theme_preset_colors_table[9];
extern DF_CmdParamSlot df_g_cmd_param_slot_2_view_spec_src_map[7];
extern String8 df_g_cmd_param_slot_2_view_spec_dst_map[7];
extern String8 df_g_cmd_param_slot_2_view_spec_cmd_map[7];
extern DF_StringBindingPair df_g_default_binding_table[99];
extern DF_StringBindingPair df_g_default_binding_table[102];
extern String8 df_g_binding_version_remap_old_name_table[3];
extern String8 df_g_binding_version_remap_new_name_table[3];
extern DF_ViewSpecInfo df_g_gfx_view_kind_spec_info_table[31];