1
1
mirror of https://github.com/wez/wezterm.git synced 2024-09-11 14:25:57 +03:00

Fix compilation

This commit is contained in:
V 2024-04-08 03:26:58 +02:00 committed by Wez Furlong
parent 7c77f407fa
commit fdc805bb2e
No known key found for this signature in database
GPG Key ID: 7A7F66A31EC9B387
10 changed files with 131 additions and 71 deletions

View File

@ -4,7 +4,7 @@ use std::os::fd::AsRawFd;
use std::rc::Rc; use std::rc::Rc;
use std::sync::atomic::AtomicUsize; use std::sync::atomic::AtomicUsize;
use anyhow::{bail, Context}; use anyhow::{anyhow, bail, Context};
use mio::unix::SourceFd; use mio::unix::SourceFd;
use mio::{Events, Interest, Poll, Token}; use mio::{Events, Interest, Poll, Token};
use wayland_client::backend::WaylandError; use wayland_client::backend::WaylandError;
@ -58,7 +58,11 @@ impl WaylandConnection {
let mut events = Events::with_capacity(8); let mut events = Events::with_capacity(8);
let wl_fd = { let wl_fd = {
let read_guard = self.event_queue.borrow().prepare_read()?; let read_guard = self
.event_queue
.borrow()
.prepare_read()
.ok_or_else(|| anyhow!(""))?;
read_guard.connection_fd().as_raw_fd() read_guard.connection_fd().as_raw_fd()
}; };
@ -100,7 +104,7 @@ impl WaylandConnection {
continue; continue;
} }
if let Ok(guard) = event_q.prepare_read() { if let Some(guard) = event_q.prepare_read() {
if let Err(err) = guard.read() { if let Err(err) = guard.read() {
log::trace!("Event Q error: {:?}", err); log::trace!("Event Q error: {:?}", err);
if let WaylandError::Protocol(perr) = err { if let WaylandError::Protocol(perr) = err {

View File

@ -56,7 +56,7 @@ impl CopyAndPaste {
.as_ref() .as_ref()
.ok_or_else(|| anyhow!("no primary selection offer"))?; .ok_or_else(|| anyhow!("no primary selection offer"))?;
let pipe = Pipe::new().map_err(Error::msg)?; let pipe = Pipe::new().map_err(Error::msg)?;
offer.receive(TEXT_MIME_TYPE.to_string(), pipe.write.as_raw_fd()); offer.receive(TEXT_MIME_TYPE.to_string(), todo!());
Ok(pipe.read) Ok(pipe.read)
} }
None => { None => {
@ -65,7 +65,7 @@ impl CopyAndPaste {
.as_ref() .as_ref()
.ok_or_else(|| anyhow!("no data offer"))?; .ok_or_else(|| anyhow!("no data offer"))?;
let pipe = Pipe::new().map_err(Error::msg)?; let pipe = Pipe::new().map_err(Error::msg)?;
offer.receive(TEXT_MIME_TYPE.to_string(), pipe.write.as_raw_fd()); offer.receive(TEXT_MIME_TYPE.to_string(), todo!());
Ok(pipe.read) Ok(pipe.read)
} }
} }

View File

@ -0,0 +1,33 @@
use smithay_client_toolkit::globals::GlobalData;
use wayland_client::Dispatch;
use wayland_protocols::wp::cursor_shape::v1::client::wp_cursor_shape_device_v1::WpCursorShapeDeviceV1;
use wayland_protocols::wp::cursor_shape::v1::client::wp_cursor_shape_manager_v1::WpCursorShapeManagerV1;
use super::state::WaylandState;
pub(super) struct CursorShapeManagerState {}
impl Dispatch<WpCursorShapeManagerV1, GlobalData, WaylandState> for CursorShapeManagerState {
fn event(
state: &mut WaylandState,
proxy: &WpCursorShapeManagerV1,
event: <WpCursorShapeManagerV1 as wayland_client::Proxy>::Event,
data: &GlobalData,
conn: &wayland_client::Connection,
qhandle: &wayland_client::QueueHandle<WaylandState>,
) {
todo!()
}
}
impl Dispatch<WpCursorShapeDeviceV1, GlobalData, WaylandState> for CursorShapeManagerState {
fn event(
state: &mut WaylandState,
proxy: &WpCursorShapeDeviceV1,
event: <WpCursorShapeDeviceV1 as wayland_client::Proxy>::Event,
data: &GlobalData,
conn: &wayland_client::Connection,
qhandle: &wayland_client::QueueHandle<WaylandState>,
) {
todo!()
}
}

View File

@ -1,12 +1,13 @@
use std::os::fd::{FromRawFd, IntoRawFd}; use std::os::fd::{FromRawFd, IntoRawFd};
use filedescriptor::FileDescriptor; use filedescriptor::FileDescriptor;
use smithay_client_toolkit::data_device_manager::data_device::{ use smithay_client_toolkit::data_device_manager::data_device::DataDeviceHandler;
DataDevice, DataDeviceDataExt, DataDeviceHandler, use smithay_client_toolkit::data_device_manager::data_offer::{
DataOfferHandler, DragOffer, SelectionOffer,
}; };
use smithay_client_toolkit::data_device_manager::data_offer::DataOfferHandler;
use smithay_client_toolkit::data_device_manager::data_source::DataSourceHandler; use smithay_client_toolkit::data_device_manager::data_source::DataSourceHandler;
use smithay_client_toolkit::data_device_manager::WritePipe; 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_data_device_manager::DndAction;
use wayland_client::Proxy; use wayland_client::Proxy;
@ -26,22 +27,20 @@ impl DataDeviceHandler for WaylandState {
&mut self, &mut self,
_conn: &wayland_client::Connection, _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, _qh: &wayland_client::QueueHandle<Self>,
data_device: DataDevice, data_device: &WlDataDevice,
) { ) {
let mut drag_offer = data_device.drag_offer().unwrap(); let mut drag_offer = data_device.data::<DragOffer>().unwrap();
log::trace!( drag_offer.with_mime_types(|mime_types| {
"Data offer entered: {:?}, mime_types: {:?}", log::trace!(
drag_offer, "Data offer entered: {:?}, mime_types: {:?}",
data_device.drag_mime_types() drag_offer,
); mime_types
);
if let Some(m) = data_device if let Some(mime) = mime_types.iter().find(|s| *s == URI_MIME_TYPE) {
.drag_mime_types() drag_offer.accept_mime_type(*self.last_serial.borrow(), Some(mime.clone()));
.iter() }
.find(|s| *s == URI_MIME_TYPE) });
{
drag_offer.accept_mime_type(*self.last_serial.borrow(), Some(m.clone()));
}
drag_offer.set_actions(DndAction::None | DndAction::Copy, DndAction::None); drag_offer.set_actions(DndAction::None | DndAction::Copy, DndAction::None);
@ -64,7 +63,7 @@ impl DataDeviceHandler for WaylandState {
&mut self, &mut self,
_conn: &wayland_client::Connection, _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, _qh: &wayland_client::QueueHandle<Self>,
_data_device: DataDevice, _data_device: &WlDataDevice,
) { ) {
let pointer = self.pointer.as_mut().unwrap(); let pointer = self.pointer.as_mut().unwrap();
let mut pstate = pointer let mut pstate = pointer
@ -83,7 +82,7 @@ impl DataDeviceHandler for WaylandState {
&mut self, &mut self,
_conn: &wayland_client::Connection, _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, _qh: &wayland_client::QueueHandle<Self>,
_data_device: DataDevice, _data_device: &WlDataDevice,
) { ) {
} }
@ -91,14 +90,13 @@ impl DataDeviceHandler for WaylandState {
&mut self, &mut self,
_conn: &wayland_client::Connection, _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, _qh: &wayland_client::QueueHandle<Self>,
data_device: DataDevice, data_device: &WlDataDevice,
) { ) {
let mime_types = data_device.selection_mime_types(); if let Some(offer) = data_device.data::<SelectionOffer>() {
if !mime_types.iter().any(|s| s == TEXT_MIME_TYPE) { if !offer.with_mime_types(|mime_types| mime_types.iter().any(|s| s == TEXT_MIME_TYPE)) {
return; return;
} }
if let Some(offer) = data_device.selection_offer() {
if let Some(copy_and_paste) = self.resolve_copy_and_paste() { if let Some(copy_and_paste) = self.resolve_copy_and_paste() {
copy_and_paste copy_and_paste
.lock() .lock()
@ -112,7 +110,7 @@ impl DataDeviceHandler for WaylandState {
&mut self, &mut self,
_conn: &wayland_client::Connection, _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, _qh: &wayland_client::QueueHandle<Self>,
_data_device: DataDevice, _data_device: &WlDataDevice,
) { ) {
let pointer = self.pointer.as_mut().unwrap(); let pointer = self.pointer.as_mut().unwrap();
let mut pstate = pointer let mut pstate = pointer
@ -135,21 +133,21 @@ impl DataDeviceHandler for WaylandState {
} }
impl DataOfferHandler for WaylandState { impl DataOfferHandler for WaylandState {
fn offer( // fn offer(
&mut self, // &mut self,
_conn: &wayland_client::Connection, // _conn: &wayland_client::Connection,
_qh: &wayland_client::QueueHandle<Self>, // _qh: &wayland_client::QueueHandle<Self>,
offer: &mut smithay_client_toolkit::data_device_manager::data_offer::DataDeviceOffer, // offer: &mut smithay_client_toolkit::data_device_manager::data_offer::DataDeviceOffer,
mime_type: String, // mime_type: String,
) { // ) {
log::trace!("Received offer with mime type: {mime_type}"); // log::trace!("Received offer with mime type: {mime_type}");
if mime_type == TEXT_MIME_TYPE { // if mime_type == TEXT_MIME_TYPE {
offer.accept_mime_type(*self.last_serial.borrow(), Some(mime_type)); // offer.accept_mime_type(*self.last_serial.borrow(), Some(mime_type));
} else { // } else {
// Refuse other mime types // // Refuse other mime types
offer.accept_mime_type(*self.last_serial.borrow(), None); // offer.accept_mime_type(*self.last_serial.borrow(), None);
} // }
} // }
// Ignore drag and drop events // Ignore drag and drop events
fn source_actions( fn source_actions(

View File

@ -2,7 +2,6 @@ use crate::wayland::read_pipe_with_timeout;
use crate::ConnectionOps; use crate::ConnectionOps;
use filedescriptor::{FileDescriptor, Pipe}; use filedescriptor::{FileDescriptor, Pipe};
use smithay_client_toolkit as toolkit; use smithay_client_toolkit as toolkit;
use std::os::unix::io::AsRawFd;
use std::path::PathBuf; use std::path::PathBuf;
use toolkit::reexports::client::protocol::wl_data_offer::WlDataOffer; use toolkit::reexports::client::protocol::wl_data_offer::WlDataOffer;
use url::Url; use url::Url;
@ -33,7 +32,7 @@ impl DragAndDrop {
let pipe = Pipe::new() let pipe = Pipe::new()
.map_err(|err| log::error!("Unable to create pipe: {:#}", err)) .map_err(|err| log::error!("Unable to create pipe: {:#}", err))
.ok()?; .ok()?;
offer.receive(URI_MIME_TYPE.to_string(), pipe.write.as_raw_fd()); offer.receive(URI_MIME_TYPE.to_string(), todo!());
let read = pipe.read; let read = pipe.read;
offer.finish(); offer.finish();
Some(SurfaceAndPipe { window_id, read }) Some(SurfaceAndPipe { window_id, read })

View File

@ -8,6 +8,7 @@ pub use self::window::*;
pub use connection::*; pub use connection::*;
pub use output::*; pub use output::*;
mod copy_and_paste; mod copy_and_paste;
mod cursor_shape;
mod drag_and_drop; mod drag_and_drop;
// mod frame; // mod frame;
mod data_device; mod data_device;

View File

@ -2,10 +2,10 @@ use std::cell::RefCell;
use std::sync::{Arc, Mutex}; use std::sync::{Arc, Mutex};
use smithay_client_toolkit::compositor::SurfaceData; use smithay_client_toolkit::compositor::SurfaceData;
use smithay_client_toolkit::reexports::csd_frame::{DecorationsFrame, FrameClick};
use smithay_client_toolkit::seat::pointer::{ use smithay_client_toolkit::seat::pointer::{
PointerData, PointerDataExt, PointerEvent, PointerEventKind, PointerHandler, PointerData, PointerDataExt, PointerEvent, PointerEventKind, PointerHandler,
}; };
use smithay_client_toolkit::shell::xdg::frame::{DecorationsFrame, FrameClick};
use wayland_client::backend::ObjectId; use wayland_client::backend::ObjectId;
use wayland_client::protocol::wl_pointer::{ButtonState, WlPointer}; use wayland_client::protocol::wl_pointer::{ButtonState, WlPointer};
use wayland_client::protocol::wl_seat::WlSeat; use wayland_client::protocol::wl_seat::WlSeat;
@ -220,13 +220,17 @@ impl WaylandState {
match evt.kind { match evt.kind {
PointerEventKind::Enter { .. } => { PointerEventKind::Enter { .. } => {
inner.window_frame.click_point_moved(&evt.surface, x, y); inner
.window_frame
.click_point_moved(todo!(), &evt.surface.id(), x, y);
} }
PointerEventKind::Leave { .. } => { PointerEventKind::Leave { .. } => {
inner.window_frame.click_point_left(); inner.window_frame.click_point_left();
} }
PointerEventKind::Motion { .. } => { PointerEventKind::Motion { .. } => {
inner.window_frame.click_point_moved(&evt.surface, x, y); inner
.window_frame
.click_point_moved(todo!(), &evt.surface.id(), x, y);
} }
PointerEventKind::Press { button, serial, .. } PointerEventKind::Press { button, serial, .. }
| PointerEventKind::Release { button, serial, .. } => { | PointerEventKind::Release { button, serial, .. } => {
@ -240,7 +244,7 @@ impl WaylandState {
0x111 => FrameClick::Alternate, 0x111 => FrameClick::Alternate,
_ => continue, _ => continue,
}; };
if let Some(action) = inner.window_frame.on_click(click, pressed) { if let Some(action) = inner.window_frame.on_click(todo!(), click, pressed) {
inner.frame_action(pointer, serial, action); inner.frame_action(pointer, serial, action);
} }
} }

View File

@ -6,6 +6,7 @@ use wayland_client::{Connection, QueueHandle};
use crate::wayland::copy_and_paste::PrimarySelectionManagerData; use crate::wayland::copy_and_paste::PrimarySelectionManagerData;
use crate::wayland::keyboard::KeyboardData; use crate::wayland::keyboard::KeyboardData;
use crate::wayland::pointer::PointerUserData; use crate::wayland::pointer::PointerUserData;
use crate::wayland::SurfaceUserData;
use super::state::WaylandState; use super::state::WaylandState;
@ -39,9 +40,11 @@ impl SeatHandler for WaylandState {
log::trace!("Setting pointer capability"); log::trace!("Setting pointer capability");
let pointer = self let pointer = self
.seat .seat
.get_pointer_with_theme_and_data( .get_pointer_with_theme_and_data::<WaylandState, SurfaceUserData, PointerUserData>(
qh, qh,
&seat, &seat,
todo!(),
todo!(),
ThemeSpec::System, ThemeSpec::System,
PointerUserData::new(seat.clone()), PointerUserData::new(seat.clone()),
) )

View File

@ -3,7 +3,7 @@ use std::collections::HashMap;
use std::rc::Rc; use std::rc::Rc;
use std::sync::{Arc, Mutex}; use std::sync::{Arc, Mutex};
use smithay_client_toolkit::compositor::CompositorState; use smithay_client_toolkit::compositor::{CompositorState, SurfaceData};
use smithay_client_toolkit::data_device_manager::data_device::DataDevice; use smithay_client_toolkit::data_device_manager::data_device::DataDevice;
use smithay_client_toolkit::data_device_manager::data_source::CopyPasteSource; use smithay_client_toolkit::data_device_manager::data_source::CopyPasteSource;
use smithay_client_toolkit::data_device_manager::DataDeviceManagerState; use smithay_client_toolkit::data_device_manager::DataDeviceManagerState;
@ -20,15 +20,16 @@ use smithay_client_toolkit::shm::slot::SlotPool;
use smithay_client_toolkit::shm::{Shm, ShmHandler}; use smithay_client_toolkit::shm::{Shm, ShmHandler};
use smithay_client_toolkit::subcompositor::SubcompositorState; use smithay_client_toolkit::subcompositor::SubcompositorState;
use smithay_client_toolkit::{ use smithay_client_toolkit::{
delegate_compositor, delegate_data_device, delegate_data_device_manager, delegate_data_offer, delegate_data_source, delegate_output, delegate_registry, delegate_seat, delegate_shm, delegate_subcompositor, delegate_xdg_shell, delegate_xdg_window, registry_handlers delegate_compositor, delegate_data_device, delegate_output, delegate_registry, delegate_seat, delegate_shm, delegate_subcompositor, delegate_xdg_shell, delegate_xdg_window, registry_handlers
}; };
use wayland_client::backend::ObjectId; use wayland_client::backend::ObjectId;
use wayland_client::globals::GlobalList; use wayland_client::globals::GlobalList;
use wayland_client::protocol::wl_keyboard::WlKeyboard; use wayland_client::protocol::wl_keyboard::WlKeyboard;
use wayland_client::protocol::wl_output::WlOutput; use wayland_client::protocol::wl_output::WlOutput;
use wayland_client::protocol::wl_pointer::WlPointer; use wayland_client::protocol::wl_pointer::WlPointer;
use wayland_client::protocol::wl_surface::WlSurface;
use wayland_client::{delegate_dispatch, Connection, QueueHandle}; use wayland_client::{delegate_dispatch, Connection, QueueHandle};
use wayland_protocols::wp::cursor_shape::v1::client::wp_cursor_shape_device_v1::WpCursorShapeDeviceV1;
use wayland_protocols::wp::cursor_shape::v1::client::wp_cursor_shape_manager_v1::WpCursorShapeManagerV1;
use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_device_manager_v1::ZwpPrimarySelectionDeviceManagerV1; use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_device_manager_v1::ZwpPrimarySelectionDeviceManagerV1;
use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_device_v1::ZwpPrimarySelectionDeviceV1; use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_device_v1::ZwpPrimarySelectionDeviceV1;
use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_offer_v1::ZwpPrimarySelectionOfferV1; use wayland_protocols::wp::primary_selection::zv1::client::zwp_primary_selection_offer_v1::ZwpPrimarySelectionOfferV1;
@ -39,6 +40,7 @@ use wayland_protocols::wp::text_input::zv3::client::zwp_text_input_v3::ZwpTextIn
use crate::x11::KeyboardWithFallback; use crate::x11::KeyboardWithFallback;
use super::copy_and_paste::{PrimarySelectionManagerData, PrimarySelectionManagerState}; use super::copy_and_paste::{PrimarySelectionManagerData, PrimarySelectionManagerState};
use super::cursor_shape::CursorShapeManagerState;
use super::inputhandler::{TextInputData, TextInputState}; use super::inputhandler::{TextInputData, TextInputState};
use super::pointer::{PendingMouse, PointerUserData}; use super::pointer::{PendingMouse, PointerUserData};
use super::{OutputManagerData, OutputManagerState, SurfaceUserData, WaylandWindowInner}; use super::{OutputManagerData, OutputManagerState, SurfaceUserData, WaylandWindowInner};
@ -154,23 +156,21 @@ impl OutputHandler for WaylandState {
} }
} }
// Undocumented in sctk 0.17: This is required to use have user data with a surface // Undocumented in sctk 0.17: This is required to use have user data with a surface
// Will be just delegate_compositor!(WaylandState, surface: [SurfaceData, SurfaceUserData]) in 0.18 // Will be just this in 0.18:
delegate_dispatch!(WaylandState: [ WlSurface: SurfaceUserData] => CompositorState); delegate_compositor!(WaylandState, surface: [SurfaceData, SurfaceUserData]);
// delegate_dispatch!(WaylandState: [ WlSurface: SurfaceUserData] => CompositorState);
delegate_registry!(WaylandState); delegate_registry!(WaylandState);
delegate_shm!(WaylandState); delegate_shm!(WaylandState);
delegate_output!(WaylandState); delegate_output!(WaylandState);
delegate_compositor!(WaylandState); // delegate_compositor!(WaylandState);
delegate_subcompositor!(WaylandState); delegate_subcompositor!(WaylandState);
delegate_seat!(WaylandState); delegate_seat!(WaylandState);
delegate_data_device_manager!(WaylandState);
delegate_data_device!(WaylandState); delegate_data_device!(WaylandState);
delegate_data_source!(WaylandState);
delegate_data_offer!(WaylandState);
// Updating to 0.18 should have this be able to work // Updating to 0.18 should have this be able to work
// delegate_pointer!(WaylandState, pointer: [PointerUserData]); // delegate_pointer!(WaylandState, pointer: [PointerUserData]);
@ -179,6 +179,9 @@ delegate_dispatch!(WaylandState: [WlPointer: PointerUserData] => SeatState);
delegate_xdg_shell!(WaylandState); delegate_xdg_shell!(WaylandState);
delegate_xdg_window!(WaylandState); delegate_xdg_window!(WaylandState);
delegate_dispatch!(WaylandState: [WpCursorShapeManagerV1: GlobalData] => CursorShapeManagerState);
delegate_dispatch!(WaylandState: [WpCursorShapeDeviceV1: GlobalData] => CursorShapeManagerState);
delegate_dispatch!(WaylandState: [ZwpTextInputManagerV3: GlobalData] => TextInputState); delegate_dispatch!(WaylandState: [ZwpTextInputManagerV3: GlobalData] => TextInputState);
delegate_dispatch!(WaylandState: [ZwpTextInputV3: TextInputData] => TextInputState); delegate_dispatch!(WaylandState: [ZwpTextInputV3: TextInputData] => TextInputState);

View File

@ -21,11 +21,13 @@ use raw_window_handle::{
WaylandDisplayHandle, WaylandWindowHandle, WaylandDisplayHandle, WaylandWindowHandle,
}; };
use smithay_client_toolkit::compositor::{CompositorHandler, SurfaceData, SurfaceDataExt}; use smithay_client_toolkit::compositor::{CompositorHandler, SurfaceData, SurfaceDataExt};
use smithay_client_toolkit::shell::xdg::frame::fallback_frame::FallbackFrame; use smithay_client_toolkit::reexports::csd_frame::{
use smithay_client_toolkit::shell::xdg::frame::{DecorationsFrame, FrameAction}; DecorationsFrame, FrameAction, WindowState as SCTKWindowState,
};
use smithay_client_toolkit::shell::xdg::fallback_frame::FallbackFrame;
use smithay_client_toolkit::shell::xdg::window::{ use smithay_client_toolkit::shell::xdg::window::{
DecorationMode, Window as XdgWindow, WindowConfigure, WindowDecorations as Decorations, DecorationMode, Window as XdgWindow, WindowConfigure, WindowDecorations as Decorations,
WindowHandler, WindowState as SCTKWindowState, WindowHandler,
}; };
use smithay_client_toolkit::shell::xdg::XdgSurface; use smithay_client_toolkit::shell::xdg::XdgSurface;
use smithay_client_toolkit::shell::WaylandSurface; use smithay_client_toolkit::shell::WaylandSurface;
@ -917,13 +919,13 @@ impl WaylandWindowInner {
let (shm, pointer) = let (shm, pointer) =
RefMut::map_split(state, |s| (&mut s.shm, s.pointer.as_mut().unwrap())); RefMut::map_split(state, |s| (&mut s.shm, s.pointer.as_mut().unwrap()));
// Much different API in 0.18
if let Err(err) = pointer.set_cursor( if let Err(err) = pointer.set_cursor(
&conn.connection, &conn.connection,
name, todo!(),
shm.wl_shm(), // name,
&self.pointer_surface, // shm.wl_shm(),
1, // &self.pointer_surface,
// 1,
) { ) {
log::error!("set_cursor: {}", err); log::error!("set_cursor: {}", err);
} }
@ -1156,8 +1158,11 @@ impl WaylandWindowInner {
.unwrap() .unwrap()
.show_window_menu(seat, serial, (x, y)) .show_window_menu(seat, serial, (x, y))
} }
FrameAction::Resize(edge) => self.window.as_ref().unwrap().resize(seat, serial, edge), FrameAction::Resize(edge) => {
self.window.as_ref().unwrap().resize(seat, serial, todo!())
}
FrameAction::Move => self.window.as_ref().unwrap().move_(seat, serial), FrameAction::Move => self.window.as_ref().unwrap().move_(seat, serial),
_ => todo!(),
} }
} }
} }
@ -1267,6 +1272,16 @@ impl CompositorHandler for WaylandState {
Ok(()) Ok(())
}); });
} }
fn transform_changed(
&mut self,
conn: &WConnection,
qh: &wayland_client::QueueHandle<Self>,
surface: &wayland_client::protocol::wl_surface::WlSurface,
new_transform: wayland_client::protocol::wl_output::Transform,
) {
todo!()
}
} }
impl WindowHandler for WaylandState { impl WindowHandler for WaylandState {