@@ -11,7 +11,7 @@ https://github.com/1Password/arboard/pull/50
1111 /// The native clipboard is not accessible due to being held by an other party.
1212--- /dev/null
1313+++ b/src/platform/dummy.rs
14- @@ -0,0 +1,78 @@
14+ @@ -0,0 +1,86 @@
1515+ /*
1616+ SPDX-License-Identifier: Apache-2.0 OR MIT
1717+
@@ -25,7 +25,7 @@ https://github.com/1Password/arboard/pull/50
2525+ use crate::common::Error;
2626+ #[cfg(feature = "image-data")]
2727+ use crate::common::ImageData;
28- + use std::borrow::Cow;
28+ + use std::{ borrow::Cow, path::PathBuf} ;
2929+
3030+ pub(crate) struct Clipboard { }
3131+
@@ -52,6 +52,14 @@ https://github.com/1Password/arboard/pull/50
5252+ pub(crate) fn image(self) -> Result<ImageData<'static>, Error> {
5353+ Err(Error::ContentNotAvailable)
5454+ }
55+ +
56+ + pub(crate) fn html(self) -> Result<String, Error> {
57+ + Err(Error::ContentNotAvailable)
58+ + }
59+ +
60+ + pub(crate) fn file_list(self) -> Result<Vec<PathBuf>, Error> {
61+ + Err(Error::ContentNotAvailable)
62+ + }
5563+ }
5664+
5765+ pub(crate) struct Set<'clipboard> {
@@ -63,16 +71,16 @@ https://github.com/1Password/arboard/pull/50
6371+ Self { clipboard }
6472+ }
6573+
66- + pub(crate) fn text(self, data : Cow<'_, str>) -> Result<(), Error> {
74+ + pub(crate) fn text(self, _data : Cow<'_, str>) -> Result<(), Error> {
6775+ Err(Error::ClipboardNotSupported)
6876+ }
6977+
70- + pub(crate) fn html(self, html : Cow<'_, str>, alt : Option<Cow<'_, str>>) -> Result<(), Error> {
78+ + pub(crate) fn html(self, _html : Cow<'_, str>, _alt : Option<Cow<'_, str>>) -> Result<(), Error> {
7179+ Err(Error::ClipboardNotSupported)
7280+ }
7381+
7482+ #[cfg(feature = "image-data")]
75- + pub(crate) fn image(self, data : ImageData) -> Result<(), Error> {
83+ + pub(crate) fn image(self, _data : ImageData) -> Result<(), Error> {
7684+ Err(Error::ClipboardNotSupported)
7785+ }
7886+ }
0 commit comments