mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-29 06:02:07 +03: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
Notes:
sideshowbarker
2024-07-18 22:46:33 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/3c7f5392a96
@ -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…
Reference in New Issue
Block a user