Register and disassembly view now separated in different tabs
This commit is contained in:
@@ -67,7 +67,10 @@ void InstructionFunc(s64, Disassembler::DisassemblyResult& disasm) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void Debugger::RegisterView() {
|
void Debugger::RegisterView() {
|
||||||
if(!ImGui::BeginTable("Registers", 4, ImGuiTableFlags_SizingStretchSame | ImGuiTableFlags_Resizable | ImGuiTableFlags_BordersOuter | ImGuiTableFlags_BordersV | ImGuiTableFlags_ContextMenuInBody))
|
if(!ImGui::BeginTabItem("Registers"))
|
||||||
|
return;
|
||||||
|
|
||||||
|
if(!ImGui::BeginTable("##regs", 4, ImGuiTableFlags_SizingStretchSame | ImGuiTableFlags_Resizable | ImGuiTableFlags_BordersOuter | ImGuiTableFlags_BordersV | ImGuiTableFlags_ContextMenuInBody))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
ImGui::TableSetupColumn("Name");
|
ImGui::TableSetupColumn("Name");
|
||||||
@@ -140,6 +143,7 @@ void Debugger::RegisterView() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ImGui::EndTable();
|
ImGui::EndTable();
|
||||||
|
ImGui::EndTabItem();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Debugger::render() {
|
bool Debugger::render() {
|
||||||
@@ -178,10 +182,25 @@ bool Debugger::render() {
|
|||||||
core.ToggleBreakpoint(startAddr);
|
core.ToggleBreakpoint(startAddr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!ImGui::BeginTabBar("##debuggerTabs")) {
|
||||||
|
ImGui::EndTabBar();
|
||||||
|
ImGui::End();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
RegisterView();
|
||||||
|
|
||||||
|
if(!ImGui::BeginTabItem("MIPS R4300i code view")) {
|
||||||
|
ImGui::EndTabBar();
|
||||||
|
ImGui::End();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
constexpr auto disasmTableFlags = ImGuiTableFlags_SizingFixedSame | ImGuiTableFlags_Resizable | ImGuiTableFlags_BordersOuter |
|
constexpr auto disasmTableFlags = ImGuiTableFlags_SizingFixedSame | ImGuiTableFlags_Resizable | ImGuiTableFlags_BordersOuter |
|
||||||
ImGuiTableFlags_BordersV | ImGuiTableFlags_ContextMenuInBody;
|
ImGuiTableFlags_BordersV | ImGuiTableFlags_ContextMenuInBody;
|
||||||
|
|
||||||
if(!ImGui::BeginTable("Disassembly", columns.size(), disasmTableFlags)) {
|
if(!ImGui::BeginTable("Disassembly", columns.size(), disasmTableFlags)) {
|
||||||
|
ImGui::EndTabBar();
|
||||||
ImGui::End();
|
ImGui::End();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -222,7 +241,8 @@ bool Debugger::render() {
|
|||||||
|
|
||||||
ImGui::EndTable();
|
ImGui::EndTable();
|
||||||
|
|
||||||
RegisterView();
|
ImGui::EndTabItem();
|
||||||
|
ImGui::EndTabBar();
|
||||||
|
|
||||||
ImGui::End();
|
ImGui::End();
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user