all: address clippy lints
This commit is contained in:
parent
84ac6d47d0
commit
0a20f03a81
6 changed files with 50 additions and 15 deletions
|
|
@ -5,6 +5,7 @@ use {
|
|||
ei_client::{EiClient, EiClientError},
|
||||
ei_ifs::{
|
||||
ei_callback::EiCallback,
|
||||
ei_pingpong::EiPingpong,
|
||||
ei_seat::{
|
||||
EI_CAP_BUTTON, EI_CAP_KEYBOARD, EI_CAP_POINTER, EI_CAP_POINTER_ABSOLUTE,
|
||||
EI_CAP_SCROLL, EI_CAP_TOUCHSCREEN, EiSeat,
|
||||
|
|
@ -18,7 +19,7 @@ use {
|
|||
EiButton, EiConnectionId, EiKeyboard, EiPointer, EiPointerAbsolute, EiScroll,
|
||||
EiTouchscreen,
|
||||
ei_connection::{
|
||||
Disconnect, Disconnected, EiConnectionRequestHandler, InvalidObject, Seat,
|
||||
Disconnect, Disconnected, EiConnectionRequestHandler, InvalidObject, Ping, Seat,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
@ -59,6 +60,15 @@ impl EiConnection {
|
|||
});
|
||||
}
|
||||
|
||||
#[expect(dead_code)]
|
||||
pub fn send_ping(&self, ping: &EiPingpong, version: u32) {
|
||||
self.client.event(Ping {
|
||||
self_id: self.id,
|
||||
ping: ping.id,
|
||||
version,
|
||||
});
|
||||
}
|
||||
|
||||
pub fn announce_seat(&self, seat: &Rc<WlSeatGlobal>) {
|
||||
let version = self.client.versions.ei_seat.version.get();
|
||||
if version == EiVersion(0) {
|
||||
|
|
|
|||
|
|
@ -16,8 +16,9 @@ use {
|
|||
EiDeviceId,
|
||||
ei_device::{
|
||||
ClientFrame, ClientStartEmulating, ClientStopEmulating, Destroyed, DeviceType,
|
||||
Done, EiDeviceRequestHandler, Interface, Paused, Region, RegionMappingId, Release,
|
||||
Resumed, ServerFrame, ServerStartEmulating,
|
||||
Dimensions, Done, EiDeviceRequestHandler, Interface, Name, Paused, Region,
|
||||
RegionMappingId, Release, Resumed, ServerFrame, ServerStartEmulating,
|
||||
ServerStopEmulating,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
@ -92,6 +93,31 @@ impl EiDevice {
|
|||
});
|
||||
}
|
||||
|
||||
#[expect(dead_code)]
|
||||
pub fn send_stop_emulating(&self, serial: u32) {
|
||||
self.client.event(ServerStopEmulating {
|
||||
self_id: self.id,
|
||||
serial,
|
||||
});
|
||||
}
|
||||
|
||||
#[expect(dead_code)]
|
||||
pub fn send_dimensions(&self, width: u32, height: u32) {
|
||||
self.client.event(Dimensions {
|
||||
self_id: self.id,
|
||||
width,
|
||||
height,
|
||||
});
|
||||
}
|
||||
|
||||
#[expect(dead_code)]
|
||||
pub fn send_name(&self, name: &str) {
|
||||
self.client.event(Name {
|
||||
self_id: self.id,
|
||||
name,
|
||||
});
|
||||
}
|
||||
|
||||
pub fn send_region(&self, rect: Rect, scale: Scale) {
|
||||
self.client.event(Region {
|
||||
self_id: self.id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue