Use /proc/meminfo for Memory module

This commit is contained in:
Robinhuett
2018-11-08 21:09:56 +01:00
parent 2d2fb88040
commit ac0963c608
2 changed files with 30 additions and 10 deletions

View File

@ -1,7 +1,7 @@
#pragma once
#include <fmt/format.h>
#include <sys/sysinfo.h>
#include <stdio.h>
#include "util/chrono.hpp"
#include "ALabel.hpp"
@ -12,6 +12,9 @@ class Memory : public ALabel {
Memory(const Json::Value&);
auto update() -> void;
private:
unsigned long memtotal_;
unsigned long memfree_;
void parseMeminfo();
waybar::util::SleeperThread thread_;
};