summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--native/src/program.rs2
-rw-r--r--src/application.rs2
-rw-r--r--src/sandbox.rs2
-rw-r--r--winit/src/conversion.rs5
4 files changed, 7 insertions, 4 deletions
diff --git a/native/src/program.rs b/native/src/program.rs
index 066c29d8..75fab094 100644
--- a/native/src/program.rs
+++ b/native/src/program.rs
@@ -11,7 +11,7 @@ pub trait Program: Sized {
type Renderer: Renderer;
/// The type of __messages__ your [`Program`] will produce.
- type Message: std::fmt::Debug + Send;
+ type Message: std::fmt::Debug + Clone + Send;
/// The type of [`Clipboard`] your [`Program`] will use.
type Clipboard: Clipboard;
diff --git a/src/application.rs b/src/application.rs
index b3dae1b3..42c28f99 100644
--- a/src/application.rs
+++ b/src/application.rs
@@ -99,7 +99,7 @@ pub trait Application: Sized {
type Executor: Executor;
/// The type of __messages__ your [`Application`] will produce.
- type Message: std::fmt::Debug + Send;
+ type Message: std::fmt::Debug + Clone + Send;
/// The data needed to initialize your [`Application`].
type Flags;
diff --git a/src/sandbox.rs b/src/sandbox.rs
index 10b05a92..cb3cf624 100644
--- a/src/sandbox.rs
+++ b/src/sandbox.rs
@@ -88,7 +88,7 @@ use crate::{
/// ```
pub trait Sandbox {
/// The type of __messages__ your [`Sandbox`] will produce.
- type Message: std::fmt::Debug + Send;
+ type Message: std::fmt::Debug + Clone + Send;
/// Initializes the [`Sandbox`].
///
diff --git a/winit/src/conversion.rs b/winit/src/conversion.rs
index 75419006..687a037e 100644
--- a/winit/src/conversion.rs
+++ b/winit/src/conversion.rs
@@ -223,7 +223,10 @@ pub fn menu<Message>(menu: &Menu<Message>) -> winit::window::Menu {
pub fn menu_message<Message>(
_menu: &Menu<Message>,
id: isize,
-) -> Option<Message> {
+) -> Option<Message>
+where
+ Message: Clone,
+{
println!("Menu entry activated: {}", id);
None