2018-08-08 23:54:33 +00:00
|
|
|
#pragma once
|
|
|
|
|
2018-08-09 11:30:11 +00:00
|
|
|
#include <json/json.h>
|
2018-08-08 23:54:33 +00:00
|
|
|
#include <fmt/format.h>
|
|
|
|
#include <sys/sysinfo.h>
|
|
|
|
#include "util/chrono.hpp"
|
2018-08-09 10:05:48 +00:00
|
|
|
#include "IModule.hpp"
|
2018-08-08 23:54:33 +00:00
|
|
|
|
|
|
|
namespace waybar::modules {
|
|
|
|
|
2018-08-16 12:29:41 +00:00
|
|
|
class Cpu : public IModule {
|
|
|
|
public:
|
|
|
|
Cpu(Json::Value);
|
|
|
|
auto update() -> void;
|
|
|
|
operator Gtk::Widget &();
|
|
|
|
private:
|
|
|
|
Gtk::Label label_;
|
|
|
|
waybar::util::SleeperThread thread_;
|
|
|
|
Json::Value config_;
|
|
|
|
};
|
2018-08-08 23:54:33 +00:00
|
|
|
|
|
|
|
}
|