diff --git a/CHANGELOG.md b/CHANGELOG.md index a75bd95..93e2119 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ - Add support for `set_parent` in XDG Portals - Update `ashpd` to 0.9. - Add support for files without an extension in XDG Portal filters +- Derive `Clone` for `FileHandle` ## 0.14.0 - i18n for GTK and XDG Portal diff --git a/src/file_handle/native.rs b/src/file_handle/native.rs index 7e0d16a..79fa179 100644 --- a/src/file_handle/native.rs +++ b/src/file_handle/native.rs @@ -110,6 +110,7 @@ impl Future for Writer { } /// FileHandle is a way of abstracting over a file returned by a dialog +#[derive(Clone)] pub struct FileHandle(PathBuf); impl FileHandle { diff --git a/src/file_handle/web.rs b/src/file_handle/web.rs index 2d97509..371a4c8 100644 --- a/src/file_handle/web.rs +++ b/src/file_handle/web.rs @@ -8,6 +8,7 @@ pub(crate) enum WasmFileHandleKind { Writable(FileDialog), } +#[derive(Clone)] pub struct FileHandle(pub(crate) WasmFileHandleKind); impl FileHandle {