mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-19 09:54:54 +00:00
SELF header display on imgui elf window
This commit is contained in:
parent
24e68b58f5
commit
cda7c67e36
3 changed files with 33 additions and 21 deletions
|
@ -11,6 +11,7 @@ void ElfViewer::display(bool enabled)
|
|||
{
|
||||
enum
|
||||
{
|
||||
SELF_HEADER,
|
||||
ELF_HEADER
|
||||
};
|
||||
static int selected = -1;
|
||||
|
@ -21,7 +22,11 @@ void ElfViewer::display(bool enabled)
|
|||
{
|
||||
if (ImGui::TreeNode("Self"))
|
||||
{
|
||||
ImGui::TreeNodeEx("Self Header", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen, "Self Header");
|
||||
if (ImGui::TreeNodeEx("Self Header", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen, "Self Header"))
|
||||
{
|
||||
if (ImGui::IsItemClicked())
|
||||
selected = SELF_HEADER;
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("Self Segment Header"))
|
||||
{
|
||||
|
@ -62,11 +67,10 @@ void ElfViewer::display(bool enabled)
|
|||
ImGui::SameLine();
|
||||
|
||||
ImGui::BeginChild("Table View", ImVec2(0, -ImGui::GetFrameHeightWithSpacing())); // Leave room for 1 line below us
|
||||
if (selected == ELF_HEADER) {
|
||||
ImGui::Text("hello");
|
||||
if (selected == SELF_HEADER) {
|
||||
ImGui::TextWrapped(elf->SElfHeaderStr().c_str());
|
||||
}
|
||||
ImGui::EndChild();
|
||||
selected = -1;
|
||||
ImGui::End();
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue