mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 13:18:13 +00:00
SystemMonitor: Trim "VMObject" suffix from VMObject types
Every VMObject type ends in "VMObject" and it's just taking up space.
This commit is contained in:
parent
ef06215e7a
commit
3c7f5392a9
1 changed files with 6 additions and 1 deletions
|
@ -93,7 +93,12 @@ ProcessMemoryMapWidget::ProcessMemoryMapWidget()
|
|||
builder.append('T');
|
||||
return builder.to_string();
|
||||
});
|
||||
pid_vm_fields.empend("vmobject", "VMObject type", Gfx::TextAlignment::CenterLeft);
|
||||
pid_vm_fields.empend("VMObject type", Gfx::TextAlignment::CenterLeft, [](auto& object) {
|
||||
auto type = object.get("vmobject").to_string();
|
||||
if (type.ends_with("VMObject"))
|
||||
type = type.substring(0, type.length() - 8);
|
||||
return type;
|
||||
});
|
||||
pid_vm_fields.empend("Purgeable", Gfx::TextAlignment::CenterLeft, [](auto& object) {
|
||||
if (object.get("volatile").to_bool())
|
||||
return "Volatile";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue