aboutsummaryrefslogtreecommitdiff
path: root/src/ipc/server.rs
diff options
context:
space:
mode:
authorHoru <73709188+HigherOrderLogic@users.noreply.github.com>2025-08-17 16:28:24 +1000
committerGitHub <noreply@github.com>2025-08-17 09:28:24 +0300
commit271534e115e5915231c99df287bbfe396185924d (patch)
tree5642ba961a88d5f5d1f5afc0686d7b2f2476f28c /src/ipc/server.rs
parentaf30cc8df68b29973c8b9eec290f9e6b93463929 (diff)
downloadniri-271534e115e5915231c99df287bbfe396185924d.tar.gz
niri-271534e115e5915231c99df287bbfe396185924d.tar.bz2
niri-271534e115e5915231c99df287bbfe396185924d.zip
Add ConfigLoaded event to IPC, option to disable built-in notification (#1829)
* feat: config reload ipc event * cleanups * Rename and move the new config option * rename to ConfigLoaded and emit at connection --------- Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
Diffstat (limited to 'src/ipc/server.rs')
-rw-r--r--src/ipc/server.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/ipc/server.rs b/src/ipc/server.rs
index 464a2a13..051bccab 100644
--- a/src/ipc/server.rs
+++ b/src/ipc/server.rs
@@ -762,4 +762,15 @@ impl State {
state.apply(event.clone());
server.send_event(event);
}
+
+ pub fn ipc_config_loaded(&mut self, failed: bool) {
+ let Some(server) = &self.niri.ipc_server else {
+ return;
+ };
+ let mut state = server.event_stream_state.borrow_mut();
+
+ let event = Event::ConfigLoaded { failed };
+ state.apply(event.clone());
+ server.send_event(event);
+ }
}