Add screenshot-window show-pointer=true

This commit is contained in:
Ivan Molodetskikh
2026-01-06 22:02:03 +03:00
parent a496307daf
commit 9f8eadc5bc
5 changed files with 99 additions and 7 deletions
+6 -1
View File
@@ -132,6 +132,7 @@ pub enum Action {
),
ScreenshotWindow(
#[knuffel(property(name = "write-to-disk"), default = true)] bool,
#[knuffel(property(name = "show-pointer"), default = false)] bool,
// Path; not settable from knuffel
Option<String>,
),
@@ -139,6 +140,7 @@ pub enum Action {
ScreenshotWindowById {
id: u64,
write_to_disk: bool,
show_pointer: bool,
path: Option<String>,
},
ToggleKeyboardShortcutsInhibit,
@@ -407,15 +409,18 @@ impl From<niri_ipc::Action> for Action {
niri_ipc::Action::ScreenshotWindow {
id: None,
write_to_disk,
show_pointer,
path,
} => Self::ScreenshotWindow(write_to_disk, path),
} => Self::ScreenshotWindow(write_to_disk, show_pointer, path),
niri_ipc::Action::ScreenshotWindow {
id: Some(id),
write_to_disk,
show_pointer,
path,
} => Self::ScreenshotWindowById {
id,
write_to_disk,
show_pointer,
path,
},
niri_ipc::Action::ToggleKeyboardShortcutsInhibit {} => {