use gtk::{ glib::{ self, subclass::{ object::{ ObjectImpl, ObjectImplExt, }, types::ObjectSubclass, InitializingObject, }, }, subclass::{application_window::ApplicationWindowImpl, widget::{ CompositeTemplateClass, CompositeTemplateInitializingExt, WidgetImpl }, window::WindowImpl}, }; #[derive(gtk::CompositeTemplate, Default)] #[template(resource = "/net/joeac/schist/window.ui")] pub struct Window { } #[glib::object_subclass] impl ObjectSubclass for Window { const NAME: &'static str = "SchistWindow"; type Type = super::Window; type ParentType = gtk::ApplicationWindow; fn class_init(klass: &mut Self::Class) { klass.bind_template(); } fn instance_init(obj: &InitializingObject) { obj.init_template(); } } impl ObjectImpl for Window { fn constructed(&self) { self.parent_constructed(); } } impl WidgetImpl for Window { } impl WindowImpl for Window { } impl ApplicationWindowImpl for Window { }