serenity/Applications/ProcessManager/NetworkStatisticsWidget.h
Andreas Kling d6bce37756 ProcessManager: Add a "Network" tab with live adapter and socket stats
This fetches info from /proc/netadapters and /proc/net_tcp, updating
every second. Very cool. :^)
2019-08-08 20:43:30 +02:00

20 lines
484 B
C++

#pragma once
#include <LibCore/CTimer.h>
#include <LibGUI/GWidget.h>
class GTableView;
class NetworkStatisticsWidget final : public GWidget {
C_OBJECT(NetworkStatisticsWidget)
public:
explicit NetworkStatisticsWidget(GWidget* parent = nullptr);
virtual ~NetworkStatisticsWidget() override;
private:
void update_models();
GTableView* m_adapter_table_view { nullptr };
GTableView* m_socket_table_view { nullptr };
CTimer* m_update_timer { nullptr };
};