1
0
Fork 0
forked from wry/wry

autocommit 2022-02-06 16:33:54 CET

This commit is contained in:
Julian Orth 2022-02-06 16:33:54 +01:00
parent c92346324b
commit dc2cb71012
104 changed files with 2563 additions and 4617 deletions

35
src/ifs/wl_callback.rs Normal file
View file

@ -0,0 +1,35 @@
use crate::client::DynEventFormatter;
use crate::object::Object;
use std::rc::Rc;
use thiserror::Error;
use crate::wire::wl_callback::*;
use crate::wire::WlCallbackId;
pub struct WlCallback {
id: WlCallbackId,
}
impl WlCallback {
pub fn new(id: WlCallbackId) -> Self {
Self { id }
}
pub fn done(self: &Rc<Self>) -> DynEventFormatter {
Box::new(Done { self_id: self.id, callback_data: 0 })
}
}
object_base! {
WlCallback, WlCallbackError;
}
impl Object for WlCallback {
fn num_requests(&self) -> u32 {
0
}
}
simple_add_obj!(WlCallback);
#[derive(Debug, Error)]
pub enum WlCallbackError {}