part 2: furthered progress on cfg switch

This commit is contained in:
Ryan Fleury
2025-01-10 12:56:53 -08:00
parent 6ce8046029
commit d9ca51b36f
9 changed files with 760 additions and 644 deletions
+5 -5
View File
@@ -191,7 +191,7 @@ RD_EntityKindFlags rd_entity_kind_flags_table[27] =
(0*RD_EntityKindFlag_CanDelete) | (0*RD_EntityKindFlag_CanFreeze) | (0*RD_EntityKindFlag_CanEdit) | (1*RD_EntityKindFlag_CanRename) | (0*RD_EntityKindFlag_CanEnable) | (0*RD_EntityKindFlag_CanCondition) | (0*RD_EntityKindFlag_CanDuplicate) | (0*RD_EntityKindFlag_NameIsCode) | (0*RD_EntityKindFlag_NameIsPath) | (0*RD_EntityKindFlag_UserDefinedLifetime) | (0*RD_EntityKindFlag_IsSerializedToConfig),
};
Rng1U64 rd_reg_slot_range_table[35] =
Rng1U64 rd_reg_slot_range_table[34] =
{
{0},
{OffsetOf(RD_Regs, machine), OffsetOf(RD_Regs, machine) + sizeof(CTRL_Handle)},
@@ -201,12 +201,11 @@ Rng1U64 rd_reg_slot_range_table[35] =
{OffsetOf(RD_Regs, ctrl_entity), OffsetOf(RD_Regs, ctrl_entity) + sizeof(CTRL_Handle)},
{OffsetOf(RD_Regs, window), OffsetOf(RD_Regs, window) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, panel), OffsetOf(RD_Regs, panel) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, tab), OffsetOf(RD_Regs, tab) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, prev_tab), OffsetOf(RD_Regs, prev_tab) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, view), OffsetOf(RD_Regs, view) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, prev_view), OffsetOf(RD_Regs, prev_view) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, dst_panel), OffsetOf(RD_Regs, dst_panel) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, entity), OffsetOf(RD_Regs, entity) + sizeof(RD_Handle)},
{OffsetOf(RD_Regs, entity_list), OffsetOf(RD_Regs, entity_list) + sizeof(RD_HandleList)},
{OffsetOf(RD_Regs, ev_key), OffsetOf(RD_Regs, ev_key) + sizeof(EV_Key)},
{OffsetOf(RD_Regs, unwind_count), OffsetOf(RD_Regs, unwind_count) + sizeof(U64)},
{OffsetOf(RD_Regs, inline_depth), OffsetOf(RD_Regs, inline_depth) + sizeof(U64)},
{OffsetOf(RD_Regs, file_path), OffsetOf(RD_Regs, file_path) + sizeof(String8)},
@@ -230,7 +229,7 @@ Rng1U64 rd_reg_slot_range_table[35] =
{OffsetOf(RD_Regs, os_event), OffsetOf(RD_Regs, os_event) + sizeof(OS_Event *)},
};
RD_CmdKindInfo rd_cmd_kind_info_table[213] =
RD_CmdKindInfo rd_cmd_kind_info_table[214] =
{
{0},
{ str8_lit_comp("launch_and_run"), str8_lit_comp("Starts debugging a new instance of a target, then runs."), str8_lit_comp("launch,start,run,target"), str8_lit_comp("Launch and Run"), RD_IconKind_Play, (RD_CmdKindFlag_ListInUI*1)|(RD_CmdKindFlag_ListInIPCDocs*1), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*1), RD_RegSlot_Entity, str8_lit_comp(""), RD_EntityKind_Target, CTRL_EntityKind_Null}},
@@ -303,6 +302,7 @@ RD_CmdKindInfo rd_cmd_kind_info_table[213] =
{ str8_lit_comp("go_back"), str8_lit_comp("Returns to the previously selected panel and tab in recorded history."), str8_lit_comp(""), str8_lit_comp("Go Back"), RD_IconKind_LeftArrow, (RD_CmdKindFlag_ListInUI*0)|(RD_CmdKindFlag_ListInIPCDocs*0), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("go_forward"), str8_lit_comp("Returns to the next selected panel and tab in recorded history."), str8_lit_comp(""), str8_lit_comp("Go Forward"), RD_IconKind_RightArrow, (RD_CmdKindFlag_ListInUI*0)|(RD_CmdKindFlag_ListInIPCDocs*0), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("close_panel"), str8_lit_comp("Closes the currently active panel."), str8_lit_comp(""), str8_lit_comp("Close Panel"), RD_IconKind_ClosePanel, (RD_CmdKindFlag_ListInUI*1)|(RD_CmdKindFlag_ListInIPCDocs*1), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("focus_tab"), str8_lit_comp("Focuses the passed tab within its containing panel."), str8_lit_comp(""), str8_lit_comp("Focus Tab"), RD_IconKind_Null, (RD_CmdKindFlag_ListInUI*0)|(RD_CmdKindFlag_ListInIPCDocs*0), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("next_tab"), str8_lit_comp("Focuses the next tab on the active panel."), str8_lit_comp(""), str8_lit_comp("Focus Next Tab"), RD_IconKind_RightArrow, (RD_CmdKindFlag_ListInUI*1)|(RD_CmdKindFlag_ListInIPCDocs*1), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("prev_tab"), str8_lit_comp("Focuses the previous tab on the active panel."), str8_lit_comp(""), str8_lit_comp("Focus Previous Tab"), RD_IconKind_LeftArrow, (RD_CmdKindFlag_ListInUI*1)|(RD_CmdKindFlag_ListInIPCDocs*1), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
{ str8_lit_comp("move_tab_right"), str8_lit_comp("Moves the selected tab right one slot."), str8_lit_comp(""), str8_lit_comp("Move Tab Right"), RD_IconKind_RightArrow, (RD_CmdKindFlag_ListInUI*1)|(RD_CmdKindFlag_ListInIPCDocs*1), {(RD_QueryFlag_AllowFiles*0)|(RD_QueryFlag_AllowFolders*0)|(RD_QueryFlag_CodeInput*0)|(RD_QueryFlag_KeepOldInput*0)|(RD_QueryFlag_SelectOldInput*0)|(RD_QueryFlag_Required*0), RD_RegSlot_Null, str8_lit_comp(""), RD_EntityKind_Nil, CTRL_EntityKind_Null}},
+8 -10
View File
@@ -57,12 +57,11 @@ RD_RegSlot_Thread,
RD_RegSlot_CtrlEntity,
RD_RegSlot_Window,
RD_RegSlot_Panel,
RD_RegSlot_Tab,
RD_RegSlot_PrevTab,
RD_RegSlot_View,
RD_RegSlot_PrevView,
RD_RegSlot_DstPanel,
RD_RegSlot_Entity,
RD_RegSlot_EntityList,
RD_RegSlot_EVKey,
RD_RegSlot_UnwindCount,
RD_RegSlot_InlineDepth,
RD_RegSlot_FilePath,
@@ -160,6 +159,7 @@ RD_CmdKind_Redo,
RD_CmdKind_GoBack,
RD_CmdKind_GoForward,
RD_CmdKind_ClosePanel,
RD_CmdKind_FocusTab,
RD_CmdKind_NextTab,
RD_CmdKind_PrevTab,
RD_CmdKind_MoveTabRight,
@@ -548,12 +548,11 @@ CTRL_Handle thread;
CTRL_Handle ctrl_entity;
RD_Handle window;
RD_Handle panel;
RD_Handle tab;
RD_Handle prev_tab;
RD_Handle view;
RD_Handle prev_view;
RD_Handle dst_panel;
RD_Handle entity;
RD_HandleList entity_list;
EV_Key ev_key;
U64 unwind_count;
U64 inline_depth;
String8 file_path;
@@ -620,12 +619,11 @@ RD_ViewRuleUIFunctionType *ui;
.ctrl_entity = rd_regs()->ctrl_entity,\
.window = rd_regs()->window,\
.panel = rd_regs()->panel,\
.tab = rd_regs()->tab,\
.prev_tab = rd_regs()->prev_tab,\
.view = rd_regs()->view,\
.prev_view = rd_regs()->prev_view,\
.dst_panel = rd_regs()->dst_panel,\
.entity = rd_regs()->entity,\
.entity_list = rd_regs()->entity_list,\
.ev_key = rd_regs()->ev_key,\
.unwind_count = rd_regs()->unwind_count,\
.inline_depth = rd_regs()->inline_depth,\
.file_path = rd_regs()->file_path,\
@@ -767,7 +765,7 @@ extern String8 d_entity_kind_name_lower_table[27];
extern String8 d_entity_kind_name_lower_plural_table[27];
extern String8 d_entity_kind_name_label_table[27];
extern RD_EntityKindFlags rd_entity_kind_flags_table[27];
extern Rng1U64 rd_reg_slot_range_table[35];
extern Rng1U64 rd_reg_slot_range_table[34];
extern RD_StringBindingPair rd_default_binding_table[110];
extern String8 rd_binding_version_remap_old_name_table[8];
extern String8 rd_binding_version_remap_new_name_table[8];