From 1dcff9396aaaf1106c5ef7b657338b94e46d40e5 Mon Sep 17 00:00:00 2001 From: patrick96 Date: Sun, 28 Aug 2022 15:05:22 +0200 Subject: [PATCH] tray: Stop listening to ui::visibility_change If the bar window (un)maps, the tray icons are automatically (un)mapped --- include/x11/tray_manager.hpp | 3 +-- src/x11/tray_manager.cpp | 9 --------- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/include/x11/tray_manager.hpp b/include/x11/tray_manager.hpp index d671d33e..54d6947e 100644 --- a/include/x11/tray_manager.hpp +++ b/include/x11/tray_manager.hpp @@ -60,7 +60,7 @@ class tray_manager : public xpp::event::sink, - public signal_receiver { public: using make_type = unique_ptr; @@ -126,7 +126,6 @@ class tray_manager void handle(const evt::map_notify& evt) override; void handle(const evt::unmap_notify& evt) override; - bool on(const signals::ui::visibility_change& evt) override; bool on(const signals::ui::update_background& evt) override; bool on(const signals::ui_tray::tray_pos_change& evt) override; bool on(const signals::ui_tray::tray_visibility& evt) override; diff --git a/src/x11/tray_manager.cpp b/src/x11/tray_manager.cpp index 1064f0bc..46f732f7 100644 --- a/src/x11/tray_manager.cpp +++ b/src/x11/tray_manager.cpp @@ -716,15 +716,6 @@ void tray_manager::handle(const evt::unmap_notify& evt) { } } -/** - * Signal handler connected to the bar window's visibility change signal. - * This is used as a fallback in case the window restacking fails. It will - * toggle the tray window whenever the visibility of the bar window changes. - */ -bool tray_manager::on(const signals::ui::visibility_change& evt) { - return change_visibility(evt.cast()); -} - // TODO maybe remove signal bool tray_manager::on(const signals::ui::update_background&) { redraw_window();