mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
refactor(ALabel): add interval
This commit is contained in:
@ -30,8 +30,8 @@ class Battery : public ALabel {
|
||||
static inline const fs::path data_dir_ = "/sys/class/power_supply/";
|
||||
|
||||
void worker();
|
||||
std::tuple<uint16_t, std::string> getInfos();
|
||||
std::string getState(uint16_t);
|
||||
const std::tuple<uint8_t, std::string> getInfos() const;
|
||||
const std::string getState(uint8_t) const;
|
||||
|
||||
util::SleeperThread thread_;
|
||||
util::SleeperThread thread_timer_;
|
||||
|
@ -34,8 +34,8 @@ class Host {
|
||||
GCancellable* cancellable_ = nullptr;
|
||||
SnWatcher* watcher_ = nullptr;
|
||||
const Json::Value &config_;
|
||||
std::function<void(std::unique_ptr<Item>&)> on_add_;
|
||||
std::function<void(std::unique_ptr<Item>&)> on_remove_;
|
||||
const std::function<void(std::unique_ptr<Item>&)> on_add_;
|
||||
const std::function<void(std::unique_ptr<Item>&)> on_remove_;
|
||||
};
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user