From 94e3b1ded3304d8b41d4440350d8c8b33bc59f27 Mon Sep 17 00:00:00 2001 From: Thayne McCombs Date: Sat, 13 Jul 2024 10:49:45 -0700 Subject: [PATCH] Upgrade smithay-client-toolkit to 0.19 closes: https://github.com/wez/wezterm/pull/5781 --- Cargo.lock | 12 ++++++------ window/Cargo.toml | 4 ++-- window/src/os/wayland/data_device.rs | 6 ++++++ window/src/os/wayland/window.rs | 18 ++++++++++++++++++ 4 files changed, 32 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b20b065e65d..c6804944cbc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4894,9 +4894,9 @@ checksum = "b7c388c1b5e93756d0c740965c41e8822f866621d41acbdf6336a6a168f8840c" [[package]] name = "smithay-client-toolkit" -version = "0.18.1" +version = "0.19.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "922fd3eeab3bd820d76537ce8f582b1cf951eceb5475c28500c7457d9d17f53a" +checksum = "837d3067369e24aeda699a5d9fc5aa14ca14a84dd70aeed7156bfa04a5605b32" dependencies = [ "bitflags 2.6.0", "cursor-icon", @@ -6038,9 +6038,9 @@ dependencies = [ [[package]] name = "wayland-protocols" -version = "0.31.2" +version = "0.32.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f81f365b8b4a97f422ac0e8737c438024b5951734506b0e1d775c73030561f4" +checksum = "1794d82d869f38439d15c24b26f06f6c8603d27d47b4f786d5197c99044de415" dependencies = [ "bitflags 2.6.0", "wayland-backend", @@ -6050,9 +6050,9 @@ dependencies = [ [[package]] name = "wayland-protocols-wlr" -version = "0.2.0" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad1f61b76b6c2d8742e10f9ba5c3737f6530b4c243132c2a2ccc8aa96fe25cd6" +checksum = "fa43c961473aed713d44c1f616f775186249dfca657f256d8841ca0690366aba" dependencies = [ "bitflags 2.6.0", "wayland-backend", diff --git a/window/Cargo.toml b/window/Cargo.toml index 5d205ae00d4..3cfa26dc9b6 100644 --- a/window/Cargo.toml +++ b/window/Cargo.toml @@ -81,8 +81,8 @@ xcb-imdkit = { version="0.3", git="https://github.com/wez/xcb-imdkit-rs.git", re zbus = "4.2" zvariant = "4.0" -smithay-client-toolkit = {version = "0.18", default-features=false, optional=true} -wayland-protocols = {version="0.31", optional=true} +smithay-client-toolkit = {version = "0.19", default-features=false, optional=true} +wayland-protocols = {version="0.32", optional=true} wayland-client = {version="0.31", optional=true} wayland-egl = {version="0.32", optional=true} diff --git a/window/src/os/wayland/data_device.rs b/window/src/os/wayland/data_device.rs index d2c9a570a61..caa285be5ee 100644 --- a/window/src/os/wayland/data_device.rs +++ b/window/src/os/wayland/data_device.rs @@ -4,6 +4,7 @@ use smithay_client_toolkit::data_device_manager::data_source::DataSourceHandler; use smithay_client_toolkit::data_device_manager::WritePipe; use smithay_client_toolkit::reexports::client::protocol::wl_data_device::WlDataDevice; use wayland_client::protocol::wl_data_device_manager::DndAction; +use wayland_client::protocol::wl_surface::WlSurface; use wayland_client::Proxy; use crate::wayland::drag_and_drop::SurfaceAndOffer; @@ -23,6 +24,9 @@ impl DataDeviceHandler for WaylandState { _conn: &wayland_client::Connection, _qh: &wayland_client::QueueHandle, data_device: &WlDataDevice, + _x: f64, + _y: f64, + _surface: &WlSurface, ) { let data = match self.data_device { Some(ref dv) if dv.inner() == data_device => dv.data(), @@ -86,6 +90,8 @@ impl DataDeviceHandler for WaylandState { _conn: &wayland_client::Connection, _qh: &wayland_client::QueueHandle, _data_device: &WlDataDevice, + _x: f64, + _y: f64, ) { } diff --git a/window/src/os/wayland/window.rs b/window/src/os/wayland/window.rs index 51a81a5551d..254f42dea78 100644 --- a/window/src/os/wayland/window.rs +++ b/window/src/os/wayland/window.rs @@ -1314,6 +1314,24 @@ impl CompositorHandler for WaylandState { ) { // TODO: do we need to do anything here? } + + fn surface_enter( + &mut self, + _conn: &WConnection, + _qh: &wayland_client::QueueHandle, + _surface: &wayland_client::protocol::wl_surface::WlSurface, + _output: &wayland_client::protocol::wl_output::WlOutput, + ) { + } + + fn surface_leave( + &mut self, + _conn: &WConnection, + _qh: &wayland_client::QueueHandle, + _surface: &wayland_client::protocol::wl_surface::WlSurface, + _output: &wayland_client::protocol::wl_output::WlOutput, + ) { + } } impl WindowHandler for WaylandState {