From 742086e19063c6ea35195a3e84619ae2b5503a68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Sat, 12 Dec 2020 00:54:25 +0100 Subject: [PATCH] Update `winit` and `glutin` We avoid a breaking change in `mouse::Button::Other` for the time being. --- glutin/Cargo.toml | 2 +- winit/Cargo.toml | 2 +- winit/src/conversion.rs | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/glutin/Cargo.toml b/glutin/Cargo.toml index c6b9a34fde..505ee7e529 100644 --- a/glutin/Cargo.toml +++ b/glutin/Cargo.toml @@ -14,7 +14,7 @@ categories = ["gui"] debug = ["iced_winit/debug"] [dependencies] -glutin = "0.25" +glutin = "0.26" [dependencies.iced_native] version = "0.3" diff --git a/winit/Cargo.toml b/winit/Cargo.toml index 8929564a85..39a6a5faa6 100644 --- a/winit/Cargo.toml +++ b/winit/Cargo.toml @@ -14,7 +14,7 @@ categories = ["gui"] debug = ["iced_native/debug"] [dependencies] -winit = "0.23" +winit = "0.24" window_clipboard = "0.1" log = "0.4" thiserror = "1.0" diff --git a/winit/src/conversion.rs b/winit/src/conversion.rs index 6102b4b365..138bc64dd2 100644 --- a/winit/src/conversion.rs +++ b/winit/src/conversion.rs @@ -170,7 +170,9 @@ pub fn mouse_button(mouse_button: winit::event::MouseButton) -> mouse::Button { winit::event::MouseButton::Left => mouse::Button::Left, winit::event::MouseButton::Right => mouse::Button::Right, winit::event::MouseButton::Middle => mouse::Button::Middle, - winit::event::MouseButton::Other(other) => mouse::Button::Other(other), + winit::event::MouseButton::Other(other) => { + mouse::Button::Other(other as u8) + } } }