mirror of
https://github.com/rad4day/Waybar.git
synced 2025-07-13 22:52:30 +02:00
cpu module: Reuse getLoad of load module
This commit is contained in:
@ -21,8 +21,6 @@ class Cpu : public ALabel {
|
||||
auto update() -> void override;
|
||||
|
||||
private:
|
||||
double getCpuLoad();
|
||||
|
||||
std::vector<std::tuple<size_t, size_t>> prev_times_;
|
||||
|
||||
util::SleeperThread thread_;
|
||||
|
@ -20,8 +20,10 @@ class Load : public ALabel {
|
||||
virtual ~Load() = default;
|
||||
auto update() -> void override;
|
||||
|
||||
// This is a static member because it is also used by the cpu module.
|
||||
static std::tuple<double, double, double> getLoad();
|
||||
|
||||
private:
|
||||
std::tuple<double, double, double> getLoad();
|
||||
|
||||
util::SleeperThread thread_;
|
||||
};
|
||||
|
Reference in New Issue
Block a user