Unify context menu / hover tooltip code + UI improvements

This commit is contained in:
2025-03-02 15:20:29 -07:00
parent 8461b35cd7
commit a1f2a535e5
26 changed files with 1730 additions and 1095 deletions

View File

@@ -0,0 +1,521 @@
---
source: objdiff-core/tests/arch_ppc.rs
expression: obj
---
Object {
arch: ArchPpc {
extab: Some(
{
10: ExceptionInfo {
eti_symbol: ExtabSymbolRef {
original_index: 5,
name: "@31",
demangled_name: None,
},
etb_symbol: ExtabSymbolRef {
original_index: 4,
name: "@30",
demangled_name: None,
},
data: ExceptionTableData {
flag_val: 8200,
has_elf_vector: false,
large_frame: true,
has_frame_pointer: false,
saved_cr: false,
fpr_save_range: 0,
gpr_save_range: 4,
et_field: 0,
pc_actions: [],
exception_actions: [],
relocations: [],
},
dtors: [],
},
11: ExceptionInfo {
eti_symbol: ExtabSymbolRef {
original_index: 7,
name: "@52",
demangled_name: None,
},
etb_symbol: ExtabSymbolRef {
original_index: 6,
name: "@51",
demangled_name: None,
},
data: ExceptionTableData {
flag_val: 8200,
has_elf_vector: false,
large_frame: true,
has_frame_pointer: false,
saved_cr: false,
fpr_save_range: 0,
gpr_save_range: 4,
et_field: 0,
pc_actions: [
PCAction {
start_pc: 96,
end_pc: 96,
action_offset: 16,
},
],
exception_actions: [
ExceptionAction {
action_offset: 16,
action_type: DestroyLocal,
action_param: 0,
has_end_bit: true,
bytes: [
0,
8,
0,
0,
0,
0,
],
},
],
relocations: [
Relocation {
offset: 20,
address: 0,
},
],
},
dtors: [
ExtabSymbolRef {
original_index: 12,
name: "__dt__26__partial_array_destructorFv",
demangled_name: Some(
"__partial_array_destructor::~__partial_array_destructor()",
),
},
],
},
12: ExceptionInfo {
eti_symbol: ExtabSymbolRef {
original_index: 9,
name: "@60",
demangled_name: None,
},
etb_symbol: ExtabSymbolRef {
original_index: 8,
name: "@59",
demangled_name: None,
},
data: ExceptionTableData {
flag_val: 6152,
has_elf_vector: false,
large_frame: true,
has_frame_pointer: false,
saved_cr: false,
fpr_save_range: 0,
gpr_save_range: 3,
et_field: 0,
pc_actions: [],
exception_actions: [],
relocations: [],
},
dtors: [],
},
},
),
},
endianness: Big,
symbols: [
Symbol {
name: "NMWException.cpp",
demangled_name: None,
address: 0,
size: 0,
kind: Unknown,
section: None,
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "[.text]",
demangled_name: None,
address: 0,
size: 0,
kind: Section,
section: Some(
0,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "[extab]",
demangled_name: None,
address: 0,
size: 0,
kind: Section,
section: Some(
1,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "[extabindex]",
demangled_name: None,
address: 0,
size: 0,
kind: Section,
section: Some(
2,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@30",
demangled_name: None,
address: 0,
size: 8,
kind: Object,
section: Some(
1,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@31",
demangled_name: None,
address: 0,
size: 12,
kind: Object,
section: Some(
2,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@51",
demangled_name: None,
address: 8,
size: 24,
kind: Object,
section: Some(
1,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@52",
demangled_name: None,
address: 12,
size: 12,
kind: Object,
section: Some(
2,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@59",
demangled_name: None,
address: 32,
size: 8,
kind: Object,
section: Some(
1,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "@60",
demangled_name: None,
address: 24,
size: 12,
kind: Object,
section: Some(
2,
),
flags: FlagSet(Local),
align: None,
virtual_address: None,
},
Symbol {
name: "__destroy_arr",
demangled_name: None,
address: 0,
size: 120,
kind: Function,
section: Some(
0,
),
flags: FlagSet(Global | HasExtra),
align: None,
virtual_address: None,
},
Symbol {
name: "__construct_array",
demangled_name: None,
address: 120,
size: 248,
kind: Function,
section: Some(
0,
),
flags: FlagSet(Global | HasExtra),
align: None,
virtual_address: None,
},
Symbol {
name: "__dt__26__partial_array_destructorFv",
demangled_name: Some(
"__partial_array_destructor::~__partial_array_destructor()",
),
address: 368,
size: 184,
kind: Function,
section: Some(
0,
),
flags: FlagSet(Global | Weak | HasExtra),
align: None,
virtual_address: None,
},
Symbol {
name: "__dl__FPv",
demangled_name: Some(
"operator delete(void*)",
),
address: 0,
size: 0,
kind: Unknown,
section: None,
flags: FlagSet(Global),
align: None,
virtual_address: None,
},
],
sections: [
Section {
id: ".text-0",
name: ".text",
address: 0,
size: 552,
kind: Code,
data: SectionData(
552,
),
flags: FlagSet(),
relocations: [
Relocation {
flags: Elf(
10,
),
address: 516,
target_symbol: 13,
addend: 0,
},
],
line_info: {},
virtual_address: None,
},
Section {
id: "extab-0",
name: "extab",
address: 0,
size: 40,
kind: Data,
data: SectionData(
40,
),
flags: FlagSet(),
relocations: [
Relocation {
flags: Elf(
1,
),
address: 28,
target_symbol: 12,
addend: 0,
},
],
line_info: {},
virtual_address: None,
},
Section {
id: "extabindex-0",
name: "extabindex",
address: 0,
size: 36,
kind: Data,
data: SectionData(
36,
),
flags: FlagSet(),
relocations: [
Relocation {
flags: Elf(
1,
),
address: 0,
target_symbol: 10,
addend: 0,
},
Relocation {
flags: Elf(
1,
),
address: 8,
target_symbol: 4,
addend: 0,
},
Relocation {
flags: Elf(
1,
),
address: 12,
target_symbol: 11,
addend: 0,
},
Relocation {
flags: Elf(
1,
),
address: 20,
target_symbol: 6,
addend: 0,
},
Relocation {
flags: Elf(
1,
),
address: 24,
target_symbol: 12,
addend: 0,
},
Relocation {
flags: Elf(
1,
),
address: 32,
target_symbol: 8,
addend: 0,
},
],
line_info: {},
virtual_address: None,
},
Section {
id: ".rela.text-0",
name: ".rela.text",
address: 0,
size: 12,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".relaextab-0",
name: ".relaextab",
address: 0,
size: 12,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".relaextabindex-0",
name: ".relaextabindex",
address: 0,
size: 72,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".symtab-0",
name: ".symtab",
address: 0,
size: 240,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".strtab-0",
name: ".strtab",
address: 0,
size: 121,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".shstrtab-0",
name: ".shstrtab",
address: 0,
size: 97,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
Section {
id: ".comment-0",
name: ".comment",
address: 0,
size: 164,
kind: Unknown,
data: SectionData(
0,
),
flags: FlagSet(),
relocations: [],
line_info: {},
virtual_address: None,
},
],
split_meta: None,
path: None,
timestamp: None,
}

View File

@@ -6,6 +6,7 @@ Object {
arch: ArchPpc {
extab: None,
},
endianness: Big,
symbols: [
Symbol {
name: "IObj.cpp",

View File

@@ -7,6 +7,7 @@ Object {
bits: 32,
endianness: Little,
},
endianness: Little,
symbols: [
Symbol {
name: "objdiffstaticdebug.cpp",