tray: remove tray-position = adaptive (#2726)

The tray is automatically started if there is a tray module. In addition, `tray-position` and the tray module conflict.

Ref #2689
This commit is contained in:
raffael0
2022-06-15 11:09:13 +02:00
committed by GitHub
parent 6a43758b5b
commit 86f2baa550
6 changed files with 43 additions and 30 deletions

View File

@ -267,7 +267,7 @@ void controller::read_events(bool confwatch) {
}
if (!m_writeback) {
m_bar->start();
m_bar->start(m_tray_module_name);
}
/*
@ -593,6 +593,13 @@ size_t controller::setup_modules(alignment align) {
try {
auto type = m_conf.get("module/" + module_name, "type");
if (type == tray_module::TYPE) {
if (!m_tray_module_name.empty()) {
throw module_error("Multiple trays defined. Using tray `" + m_tray_module_name + "`");
}
m_tray_module_name = module_name;
}
if (type == ipc_module::TYPE && !m_has_ipc) {
throw application_error("Inter-process messaging needs to be enabled");
}