[][src]Trait glib::subclass::object::ObjectImpl

pub trait ObjectImpl: ObjectImplExt + 'static {
    fn get_type_data(&self) -> NonNull<TypeData>;

    fn set_property(&self, _obj: &Object, _id: usize, _value: &Value) { ... }
fn get_property(&self, _obj: &Object, _id: usize) -> Result<Value, ()> { ... }
fn constructed(&self, obj: &Object) { ... } }

Trait for implementors of glib::Object subclasses.

This allows overriding the virtual methods of glib::Object.

Required methods

fn get_type_data(&self) -> NonNull<TypeData>

Storage for the type-specific data used during registration.

This is usually generated by the glib_object_impl! macro.

Loading content...

Provided methods

fn set_property(&self, _obj: &Object, _id: usize, _value: &Value)

Property setter.

This is called whenever the property of this specific subclass with the given index is set. The new value is passed as glib::Value.

fn get_property(&self, _obj: &Object, _id: usize) -> Result<Value, ()>

Property getter.

This is called whenever the property value of the specific subclass with the given index should be returned.

fn constructed(&self, obj: &Object)


This is called once construction of the instance is finished.

Should chain up to the parent class' implementation.

Loading content...


Loading content...