mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-03-26 06:30:56 +03:00
adapt config backend options to cli arg names
This commit is contained in:
@@ -86,15 +86,21 @@ struct CliArgs {
|
|||||||
#[derive(Clone, Copy, Debug, Deserialize, Eq, PartialEq, Serialize, ValueEnum)]
|
#[derive(Clone, Copy, Debug, Deserialize, Eq, PartialEq, Serialize, ValueEnum)]
|
||||||
pub enum CaptureBackend {
|
pub enum CaptureBackend {
|
||||||
#[cfg(all(unix, feature = "libei", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "libei", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "input-capture-portal")]
|
||||||
InputCapturePortal,
|
InputCapturePortal,
|
||||||
#[cfg(all(unix, feature = "wayland", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "wayland", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "layer-shell")]
|
||||||
LayerShell,
|
LayerShell,
|
||||||
#[cfg(all(unix, feature = "x11", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "x11", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "x11")]
|
||||||
X11,
|
X11,
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
|
#[serde(rename = "windows")]
|
||||||
Windows,
|
Windows,
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
|
#[serde(rename = "macos")]
|
||||||
MacOs,
|
MacOs,
|
||||||
|
#[serde(rename = "dummy")]
|
||||||
Dummy,
|
Dummy,
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -137,17 +143,24 @@ impl From<CaptureBackend> for input_capture::Backend {
|
|||||||
#[derive(Clone, Copy, Debug, Deserialize, Eq, PartialEq, Serialize, ValueEnum)]
|
#[derive(Clone, Copy, Debug, Deserialize, Eq, PartialEq, Serialize, ValueEnum)]
|
||||||
pub enum EmulationBackend {
|
pub enum EmulationBackend {
|
||||||
#[cfg(all(unix, feature = "wayland", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "wayland", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "wlroots")]
|
||||||
Wlroots,
|
Wlroots,
|
||||||
#[cfg(all(unix, feature = "libei", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "libei", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "libei")]
|
||||||
Libei,
|
Libei,
|
||||||
#[cfg(all(unix, feature = "xdg_desktop_portal", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "xdg_desktop_portal", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "xdp")]
|
||||||
Xdp,
|
Xdp,
|
||||||
#[cfg(all(unix, feature = "x11", not(target_os = "macos")))]
|
#[cfg(all(unix, feature = "x11", not(target_os = "macos")))]
|
||||||
|
#[serde(rename = "x11")]
|
||||||
X11,
|
X11,
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
|
#[serde(rename = "windows")]
|
||||||
Windows,
|
Windows,
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
|
#[serde(rename = "macos")]
|
||||||
MacOs,
|
MacOs,
|
||||||
|
#[serde(rename = "dummy")]
|
||||||
Dummy,
|
Dummy,
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -193,7 +206,9 @@ impl Display for EmulationBackend {
|
|||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Deserialize, PartialEq, Eq, Serialize, ValueEnum)]
|
#[derive(Clone, Copy, Debug, Deserialize, PartialEq, Eq, Serialize, ValueEnum)]
|
||||||
pub enum Frontend {
|
pub enum Frontend {
|
||||||
|
#[serde(rename = "gtk")]
|
||||||
Gtk,
|
Gtk,
|
||||||
|
#[serde(rename = "cli")]
|
||||||
Cli,
|
Cli,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user