event handling & state

This commit is contained in:
Ashley Wulber 2022-06-16 11:55:31 -04:00
parent d991f59c90
commit 3a41e58159
15 changed files with 212 additions and 68 deletions

View file

@ -10,7 +10,7 @@ use gtk4::{
use once_cell::sync::OnceCell;
use std::sync::{Arc, Mutex};
use tokio::sync::mpsc;
use utils::{Activate, Workspace};
use utils::{Activate, WorkspaceEvent};
use window::CosmicWorkspacesWindow;
mod localize;
@ -56,7 +56,7 @@ fn main() {
app.connect_activate(|app| {
load_css();
let (tx, mut rx) = mpsc::channel::<Vec<Workspace>>(100);
let (tx, mut rx) = mpsc::channel::<Vec<WorkspaceEvent>>(100);
let wayland_tx = wayland::spawn_workspaces(tx.clone());
let window = CosmicWorkspacesWindow::new(app);