From e6f3c538da0c646bda43fcde7ef7dc3b771e0c8b Mon Sep 17 00:00:00 2001 From: Kainoa Kanter Date: Sat, 25 Oct 2025 23:33:49 -0700 Subject: feat: event-stream event for when a screenshot is taken (#2565) * feat: event-stream event for when a screenshot is taken * ScreenshotTaken --> ScreenshotCaptured * review comments * fix: screenshot completion event path serializatation * fixes --------- Co-authored-by: Ivan Molodetskikh --- niri-ipc/src/lib.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'niri-ipc') diff --git a/niri-ipc/src/lib.rs b/niri-ipc/src/lib.rs index 05c3a2ec..afe9a6d2 100644 --- a/niri-ipc/src/lib.rs +++ b/niri-ipc/src/lib.rs @@ -1483,6 +1483,14 @@ pub enum Event { /// For example, the config file couldn't be parsed. failed: bool, }, + /// A screenshot was captured. + ScreenshotCaptured { + /// The file path where the screenshot was saved, if it was written to disk. + /// + /// If `None`, the screenshot was either only copied to the clipboard, or the path couldn't + /// be converted to a `String` (e.g. contained invalid UTF-8 bytes). + path: Option, + }, } impl FromStr for WorkspaceReferenceArg { -- cgit