mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-03 09:48:47 +00:00
LibGUI: Put all classes in the GUI namespace and remove the leading G
This took me a moment. Welcome to the new world of GUI::Widget! :^)
This commit is contained in:
parent
2d39da5405
commit
c5bd9d4ed1
Notes:
sideshowbarker
2024-07-19 09:41:33 +09:00
Author: https://github.com/awesomekling
Commit: c5bd9d4ed1
337 changed files with 5400 additions and 4816 deletions
|
@ -31,14 +31,14 @@
|
|||
#include <LibGUI/GSortingProxyModel.h>
|
||||
#include <LibGUI/GTableView.h>
|
||||
|
||||
ProcessMemoryMapWidget::ProcessMemoryMapWidget(GWidget* parent)
|
||||
: GWidget(parent)
|
||||
ProcessMemoryMapWidget::ProcessMemoryMapWidget(GUI::Widget* parent)
|
||||
: GUI::Widget(parent)
|
||||
{
|
||||
set_layout(make<GVBoxLayout>());
|
||||
set_layout(make<GUI::VBoxLayout>());
|
||||
layout()->set_margins({ 4, 4, 4, 4 });
|
||||
m_table_view = GTableView::construct(this);
|
||||
m_table_view = GUI::TableView::construct(this);
|
||||
m_table_view->set_size_columns_to_fit_content(true);
|
||||
Vector<GJsonArrayModel::FieldSpec> pid_vm_fields;
|
||||
Vector<GUI::JsonArrayModel::FieldSpec> pid_vm_fields;
|
||||
pid_vm_fields.empend("Address", TextAlignment::CenterLeft, [](auto& object) {
|
||||
return String::format("%#x", object.get("address").to_u32());
|
||||
});
|
||||
|
@ -70,9 +70,9 @@ ProcessMemoryMapWidget::ProcessMemoryMapWidget(GWidget* parent)
|
|||
});
|
||||
pid_vm_fields.empend("cow_pages", "# CoW", TextAlignment::CenterRight);
|
||||
pid_vm_fields.empend("name", "Name", TextAlignment::CenterLeft);
|
||||
m_json_model = GJsonArrayModel::create({}, move(pid_vm_fields));
|
||||
m_table_view->set_model(GSortingProxyModel::create(*m_json_model));
|
||||
m_table_view->model()->set_key_column_and_sort_order(0, GSortOrder::Ascending);
|
||||
m_json_model = GUI::JsonArrayModel::create({}, move(pid_vm_fields));
|
||||
m_table_view->set_model(GUI::SortingProxyModel::create(*m_json_model));
|
||||
m_table_view->model()->set_key_column_and_sort_order(0, GUI::SortOrder::Ascending);
|
||||
m_timer = Core::Timer::construct(1000, [this] { refresh(); }, this);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue