diff --git a/gtk4/src/subclass/widget.rs b/gtk4/src/subclass/widget.rs index 369fadaf7159..588802208d1d 100644 --- a/gtk4/src/subclass/widget.rs +++ b/gtk4/src/subclass/widget.rs @@ -1230,6 +1230,19 @@ where } } +impl glib::HasParamSpec for TemplateChild +where + T: ObjectType + IsA + FromGlibPtrNone<*mut ::GlibType>, +{ + type ParamSpec = glib::ParamSpecObject; + type SetValue = T; + type BuilderFn = fn(&str) -> glib::ParamSpecObjectBuilder; + + fn param_spec_builder() -> Self::BuilderFn { + Self::ParamSpec::builder + } +} + impl std::ops::Deref for TemplateChild where T: ObjectType + FromGlibPtrNone<*mut ::GlibType>,