MCPcopy Create free account
hub / github.com/Alexays/Waybar / Load

Method Load

src/modules/load.cpp:12–18  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10#endif
11
12waybar::modules::Load::Load(const std::string& id, const Json::Value& config)
13 : ALabel(config, "load", id, "{load1}", 10) {
14 thread_ = [this] {
15 dp.emit();
16 thread_.sleep_for(interval_);
17 };
18}
19
20auto waybar::modules::Load::update() -> void {
21 // TODO: as creating dynamic fmt::arg arrays is buggy we have to calc both

Callers

nothing calls this directly

Calls 2

sleep_forMethod · 0.80
emitMethod · 0.45

Tested by

no test coverage detected