]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
gtk4.vapi: Add one more metadata
authorLorenz Wildberg <lorenz@wild-fisch.de>
Fri, 28 Jul 2023 14:28:59 +0000 (17:28 +0300)
committerRico Tzschichholz <ricotz@ubuntu.com>
Wed, 31 Jan 2024 17:51:28 +0000 (18:51 +0100)
vapi/gtk4.vapi
vapi/metadata/Gtk-4.0.metadata

index 489cd46c8be5540c020ac1684cab1cfe209ace01..06b5a02deaa0095de86d57a1b380e4c1405a1383 100644 (file)
@@ -6939,8 +6939,10 @@ namespace Gtk {
                public Builder.from_resource (string resource_path);
                [CCode (has_construct_function = false)]
                public Builder.from_string (string str, ssize_t length);
-               public unowned GLib.Object? get_current_object ();
-               public unowned GLib.Object? get_object (string name);
+               [CCode (no_generic_args = true)]
+               public unowned G? get_current_object<G> () where G : GLib.Object;
+               [CCode (no_generic_args = true)]
+               public unowned G? get_object<G> (string name) where G : GLib.Object;
                public GLib.SList<weak GLib.Object> get_objects ();
                public unowned Gtk.BuilderScope get_scope ();
                public unowned string? get_translation_domain ();
index 0963fd26954aba357fb250dc734a624d37ae6c4d..0ca2763446421dc0a93fdf7f07db566ca8a57dc4 100644 (file)
@@ -29,6 +29,9 @@ TreeIter struct
 
 // Generics
 
+Builder
+  .get_*object type_parameters="GLib.Object:G" type="unowned G?"
+
 BookmarkList implements="GLib.ListModel<GLib.FileInfo>"
 DirectoryList implements="GLib.ListModel<GLib.FileInfo>"
 StringList implements="GLib.ListModel<Gtk.StringObject>"