@@ -253,7 +253,7 @@ pub enum ActivationPolicy {
253253}
254254
255255/// A [`Send`] handle to the runtime.
256- pub trait RuntimeHandle : Debug + Send + Sized + Clone + ' static {
256+ pub trait RuntimeHandle : Debug + Clone + Send + Sync + Sized + ' static {
257257 type Runtime : Runtime < Handle = Self > ;
258258 /// Create a new webview window.
259259 fn create_window (
@@ -270,7 +270,7 @@ pub trait RuntimeHandle: Debug + Send + Sized + Clone + 'static {
270270}
271271
272272/// A global shortcut manager.
273- pub trait GlobalShortcutManager : Debug {
273+ pub trait GlobalShortcutManager : Debug + Clone + Send + Sync {
274274 /// Whether the application has registered the given `accelerator`.
275275 fn is_registered ( & self , accelerator : & str ) -> crate :: Result < bool > ;
276276
@@ -289,7 +289,7 @@ pub trait GlobalShortcutManager: Debug {
289289}
290290
291291/// Clipboard manager.
292- pub trait ClipboardManager : Debug {
292+ pub trait ClipboardManager : Debug + Clone + Send + Sync {
293293 /// Writes the text into the clipboard as plain text.
294294 fn write_text < T : Into < String > > ( & mut self , text : T ) -> Result < ( ) > ;
295295 /// Read the content in the clipboard as plain text.
@@ -303,12 +303,12 @@ pub trait Runtime: Sized + 'static {
303303 /// The runtime handle type.
304304 type Handle : RuntimeHandle < Runtime = Self > ;
305305 /// The global shortcut manager type.
306- type GlobalShortcutManager : GlobalShortcutManager + Clone + Send ;
306+ type GlobalShortcutManager : GlobalShortcutManager ;
307307 /// The clipboard manager type.
308- type ClipboardManager : ClipboardManager + Clone + Send ;
308+ type ClipboardManager : ClipboardManager ;
309309 /// The tray handler type.
310310 #[ cfg( feature = "system-tray" ) ]
311- type TrayHandler : menu:: TrayHandle + Clone + Send ;
311+ type TrayHandler : menu:: TrayHandle ;
312312
313313 /// Creates a new webview runtime. Must be used on the main thread.
314314 fn new ( ) -> crate :: Result < Self > ;
@@ -353,7 +353,7 @@ pub trait Runtime: Sized + 'static {
353353}
354354
355355/// Webview dispatcher. A thread-safe handle to the webview API.
356- pub trait Dispatch : Debug + Clone + Send + Sized + ' static {
356+ pub trait Dispatch : Debug + Clone + Send + Sync + Sized + ' static {
357357 /// The runtime this [`Dispatch`] runs under.
358358 type Runtime : Runtime ;
359359
0 commit comments