mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:48:10 +00:00
ProcessManager: Show some basic system memory stats below the process table.
This really improves the feeling of "system overview" :^)
This commit is contained in:
parent
8017c1e17c
commit
37388b311f
9 changed files with 158 additions and 9 deletions
|
@ -2,7 +2,6 @@
|
|||
#include <LibGUI/GWidget.h>
|
||||
#include <LibGUI/GBoxLayout.h>
|
||||
#include <LibGUI/GApplication.h>
|
||||
#include <LibGUI/GStatusBar.h>
|
||||
#include <LibGUI/GToolBar.h>
|
||||
#include <LibGUI/GMenuBar.h>
|
||||
#include <LibGUI/GAction.h>
|
||||
|
@ -10,6 +9,7 @@
|
|||
#include <stdio.h>
|
||||
#include <signal.h>
|
||||
#include "ProcessTableView.h"
|
||||
#include "MemoryStatsWidget.h"
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
|
@ -21,10 +21,8 @@ int main(int argc, char** argv)
|
|||
|
||||
auto* toolbar = new GToolBar(widget);
|
||||
auto* process_table_view = new ProcessTableView(widget);
|
||||
auto* statusbar = new GStatusBar(widget);
|
||||
process_table_view->on_status_message = [statusbar] (String message) {
|
||||
statusbar->set_text(move(message));
|
||||
};
|
||||
|
||||
new MemoryStatsWidget(widget);
|
||||
|
||||
auto kill_action = GAction::create("Kill process", GraphicsBitmap::load_from_file(GraphicsBitmap::Format::RGBA32, "/res/icons/kill16.rgb", { 16, 16 }), [process_table_view] (const GAction&) {
|
||||
pid_t pid = process_table_view->selected_pid();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue