complete cards/game
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
use std::cell::RefCell;
|
||||
use std::sync::OnceLock;
|
||||
|
||||
use glib::subclass::InitializingObject;
|
||||
use glib::Properties;
|
||||
use gtk::glib::subclass::Signal;
|
||||
use gtk::subclass::prelude::*;
|
||||
use gtk::{glib, prelude::*, Button, CompositeTemplate, Label, Picture};
|
||||
|
||||
@@ -44,19 +42,9 @@ impl ObjectSubclass for CardEntry {
|
||||
}
|
||||
#[glib::derived_properties]
|
||||
impl ObjectImpl for CardEntry {
|
||||
|
||||
fn signals() -> &'static [Signal] {
|
||||
static SIGNALS: OnceLock<Vec<Signal>> = OnceLock::new();
|
||||
SIGNALS.get_or_init(|| {
|
||||
vec![Signal::builder("created")
|
||||
.build()]
|
||||
})
|
||||
}
|
||||
|
||||
fn constructed(&self) {
|
||||
self.parent_constructed();
|
||||
|
||||
|
||||
let hieroglyph_label_binding: &Label = self.hieroglyph_label.as_ref();
|
||||
self.obj()
|
||||
.bind_property("hieroglyph", hieroglyph_label_binding, "label")
|
||||
|
||||
Reference in New Issue
Block a user