subclass/widget: Ensure TemplateChild types are registered
Ensures types used as TemplateChild<T> are registered.
This gets rid of a step for application developers
using custom types within templates.
Closes
@@ -974,6 +974,8 @@ where
T: ObjectType + FromGlibPtrNone<*mut <T as ObjectType>::GlibType>,
{
fn default() -> Self {
+ T::static_type();
+
Self {
ptr: std::ptr::null_mut(),
}
