diff --git a/src/clip.rs b/src/clip.rs index d71ca09..fe30d7e 100644 --- a/src/clip.rs +++ b/src/clip.rs @@ -27,7 +27,7 @@ impl Selection { } } -#[derive(Clone, Default, Serialize, Deserialize)] +#[derive(Clone, Serialize, Deserialize)] pub struct ClipboardConfig { pub cmd: Option, pub shell_cmd: Option, @@ -35,6 +35,17 @@ pub struct ClipboardConfig { pub selection: Option>, } +impl Default for ClipboardConfig { + fn default() -> Self { + Self { + cmd: None, + shell_cmd: None, + osc52: true, + selection: None, + } + } +} + pub struct ClipboardManager { #[cfg(any(target_os = "linux", target_os = "windows", target_os = "macos"))] clipboard: Option, @@ -115,7 +126,10 @@ impl ClipboardManager { None => Err("The clipboard is not loaded".to_owned()), } #[cfg(not(any(target_os = "linux", target_os = "windows", target_os = "macos")))] - Err("The clipboard is not loaded".to_owned()) + Err( + "There is no native clipboard support on android\nEnable osc52 for clipboard support" + .to_owned(), + ) } #[cfg(any(target_os = "linux", target_os = "windows", target_os = "macos"))]