1
0
Fork 0
mirror of https://github.com/Zedfrigg/ironbar.git synced 2025-08-17 14:51:04 +02:00

refactor(keys): switch to colpetto

Switches from the `input` crate to new async `colpetto`
This commit is contained in:
Jake Stanger 2025-01-16 23:01:48 +00:00
parent f204b24ba0
commit a0231559d0
No known key found for this signature in database
GPG key ID: C51FC8F9CB0BEA61
6 changed files with 1188 additions and 1020 deletions

View file

@ -1,7 +1,6 @@
use super::manager::DataControlDeviceManagerState;
use crate::lock;
use nix::fcntl::OFlag;
use nix::unistd::pipe2;
use rustix::pipe::{PipeFlags, pipe_with};
use smithay_client_toolkit::data_device_manager::data_offer::DataOfferError;
use std::ops::DerefMut;
use std::os::fd::AsFd;
@ -171,7 +170,7 @@ where
/// could not be created.
pub fn receive(offer: &ZwlrDataControlOfferV1, mime_type: String) -> std::io::Result<Receiver> {
// create a pipe
let (readfd, writefd) = pipe2(OFlag::O_CLOEXEC | OFlag::O_NONBLOCK)?;
let (readfd, writefd) = pipe_with(PipeFlags::CLOEXEC)?;
offer.receive(mime_type, writefd.as_fd());