mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-03-17 23:13:55 +01:00
fix(wm): increase monitor_reconciliator channel bound
When there is a monitor disconnect/reconnect, usually it produces multiple monitor events along with it, like the monitor resolution change and the work area change. With the bound set to 1 it would sometimes result in missed events. This commit increases the bound to 20 to prevent this from happening.
This commit is contained in:
@@ -48,7 +48,7 @@ static CHANNEL: OnceLock<(Sender<MonitorNotification>, Receiver<MonitorNotificat
|
||||
static MONITOR_CACHE: OnceLock<Mutex<HashMap<String, Monitor>>> = OnceLock::new();
|
||||
|
||||
pub fn channel() -> &'static (Sender<MonitorNotification>, Receiver<MonitorNotification>) {
|
||||
CHANNEL.get_or_init(|| crossbeam_channel::bounded(1))
|
||||
CHANNEL.get_or_init(|| crossbeam_channel::bounded(20))
|
||||
}
|
||||
|
||||
fn event_tx() -> Sender<MonitorNotification> {
|
||||
|
||||
Reference in New Issue
Block a user