mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
fix(window): Ignore waybar
With this, the window title waybar will be ignored so it wont flicker as decribed in #148
This commit is contained in:
parent
a0fd99b112
commit
ce6816737c
@ -23,9 +23,11 @@ void waybar::modules::sway::Window::worker()
|
||||
try {
|
||||
auto res = ipc_.handleEvent();
|
||||
auto parsed = parser_.parse(res.payload);
|
||||
// Check for waybar prevents flicker when hovering window module
|
||||
if ((parsed["change"] == "focus" || parsed["change"] == "title")
|
||||
&& parsed["container"]["focused"].asBool()) {
|
||||
window_ = Glib::Markup::escape_text(parsed["container"]["name"].asString());
|
||||
window_ = Glib::Markup::escape_text(parsed["container"]["name"].asString()
|
||||
&& parsed["container"]["name"].asString() != "waybar");
|
||||
windowId_ = parsed["container"]["id"].asInt();
|
||||
dp.emit();
|
||||
} else if ((parsed["change"] == "close"
|
||||
|
Loading…
Reference in New Issue
Block a user