feat!(ccs): Replace run function with AppRunner trait

This commit is contained in:
Michael Aaron Murphy 2022-01-25 20:47:32 +01:00
parent 52df3570ec
commit 1ac913d5c4
No known key found for this signature in database
GPG key ID: B2732D4240C9212C
3 changed files with 30 additions and 14 deletions

View file

@ -6,10 +6,12 @@ extern crate cosmic_component_system as ccs;
mod components;
use self::components::App;
use ccs::Component;
use ccs::{AppRunner, Component};
fn main() {
ccs::run(|app| {
App::default().register(app);
});
gtk4::builders::ApplicationBuilder::new()
.application_id("org.pop.CosmicComponentExample")
.cosmic_run(|app| {
App::default().register(app);
});
}