2020-01-18 08:38:21 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
2022-02-10 19:28:48 +00:00
|
|
|
* Copyright (c) 2022, the SerenityOS developers.
|
2020-01-18 08:38:21 +00:00
|
|
|
*
|
2021-04-22 08:24:48 +00:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 08:38:21 +00:00
|
|
|
*/
|
|
|
|
|
2019-08-03 06:26:04 +00:00
|
|
|
#pragma once
|
|
|
|
|
2020-02-06 19:33:02 +00:00
|
|
|
#include <LibGUI/Widget.h>
|
2019-08-03 06:26:04 +00:00
|
|
|
|
2022-03-24 12:30:52 +00:00
|
|
|
namespace SystemMonitor {
|
|
|
|
|
2020-02-02 14:07:41 +00:00
|
|
|
class ProcessFileDescriptorMapWidget final : public GUI::Widget {
|
2023-05-21 14:47:34 +00:00
|
|
|
C_OBJECT_ABSTRACT(ProcessFileDescriptorMapWidget)
|
2020-09-18 07:49:51 +00:00
|
|
|
|
2019-08-03 06:26:04 +00:00
|
|
|
public:
|
2022-02-10 19:28:48 +00:00
|
|
|
virtual ~ProcessFileDescriptorMapWidget() override = default;
|
2019-08-03 06:26:04 +00:00
|
|
|
|
2023-05-21 14:47:34 +00:00
|
|
|
static ErrorOr<NonnullRefPtr<ProcessFileDescriptorMapWidget>> try_create();
|
|
|
|
|
2019-08-03 06:26:04 +00:00
|
|
|
void set_pid(pid_t);
|
|
|
|
|
|
|
|
private:
|
2023-05-21 14:47:34 +00:00
|
|
|
ProcessFileDescriptorMapWidget() = default;
|
2019-09-21 16:17:23 +00:00
|
|
|
|
2020-02-02 14:07:41 +00:00
|
|
|
RefPtr<GUI::TableView> m_table_view;
|
2020-09-21 22:40:57 +00:00
|
|
|
RefPtr<GUI::JsonArrayModel> m_model;
|
2019-08-03 06:26:04 +00:00
|
|
|
pid_t m_pid { -1 };
|
|
|
|
};
|
2022-03-24 12:30:52 +00:00
|
|
|
|
|
|
|
}
|