add basis for bluetooth module implementation
parent
2dc4ae78fc
commit
2c4369a653
|
@ -32,6 +32,7 @@
|
|||
#include "bar.hpp"
|
||||
#include "modules/custom.hpp"
|
||||
#include "modules/temperature.hpp"
|
||||
#include "modules/bluetooth.hpp"
|
||||
|
||||
namespace waybar {
|
||||
|
||||
|
|
|
@ -88,6 +88,7 @@ src_files = files(
|
|||
'src/ALabel.cpp',
|
||||
'src/modules/memory.cpp',
|
||||
'src/modules/battery.cpp',
|
||||
'src/modules/bluetooth.cpp',
|
||||
'src/modules/clock.cpp',
|
||||
'src/modules/custom.cpp',
|
||||
'src/modules/cpu.cpp',
|
||||
|
|
|
@ -66,6 +66,9 @@ waybar::AModule* waybar::Factory::makeModule(const std::string& name) const {
|
|||
if (ref == "temperature") {
|
||||
return new waybar::modules::Temperature(id, config_[name]);
|
||||
}
|
||||
if (ref == "bluetooth") {
|
||||
return new waybar::modules::Bluetooth(id, config_[name]);
|
||||
}
|
||||
if (ref.compare(0, 7, "custom/") == 0 && ref.size() > 7) {
|
||||
return new waybar::modules::Custom(ref.substr(7), id, config_[name]);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue