main: launch main loop and wayland sock
This commit is contained in:
parent
b7da65117e
commit
2698c06f50
5 changed files with 318 additions and 2 deletions
19
src/state.rs
Normal file
19
src/state.rs
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
use std::{cell::RefCell, rc::Rc};
|
||||
|
||||
use smithay::reexports::wayland_server::Display;
|
||||
|
||||
pub struct State {
|
||||
pub display: Rc<RefCell<Display>>,
|
||||
pub should_stop: bool,
|
||||
}
|
||||
|
||||
impl State {
|
||||
pub fn new(display: Display) -> State {
|
||||
State {
|
||||
display: Rc::new(RefCell::new(display)),
|
||||
should_stop: false,
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue