ErikReider / SwayNotificationCenter

A simple GTK based notification daemon for SwayWM

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug] waybar can only click on swaync when it has clicked on swaync once

DreamMaoMao opened this issue · comments

After clicking the swaync icon with the left mouse button on the waybar.
then,clicking on any area of the waybar with the left mouse disk will only trigger the left button command corresponding to swaync until click the right button on waybar area

2023-11-27.23-07-52.mp4

I use the example config in swaync Readme:

image

swaync version:swaync 0.9.0 (git-70eaa5b, branch 'main')
waybar version:Waybar v0.9.24-32-g1fe4a4ee (branch 'master')

image
when chang on on-click to excute other command , it will not appear this issue.

this issue will appear when on-click bind to excute "swaync-client -t -sw"

image

when i add a delay before excute swaync -t in waybar on-click config, the problem disappear.

It seems that swaync registered the mouse button monitoring before waybar canceled the button event monitoring. As a result, waybar could not exit the button monitoring of the current module normally, so waybar always thought that it was still in the mouse button monitoring of the previous module

image

A delay of at least 0.1s is required to ensure the normal exit of the waybar