[vala/staging: 6/7] gio-2.0: Make DBusInterface[GS]etPropertyFunc usable
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/staging: 6/7] gio-2.0: Make DBusInterface[GS]etPropertyFunc usable
- Date: Tue, 8 Jan 2019 17:15:42 +0000 (UTC)
commit afb9ea9687db1ca95ff169016e605f04e650cdfb
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Tue Jan 8 14:23:24 2019 +0100
gio-2.0: Make DBusInterface[GS]etPropertyFunc usable
These delegates don't place their target at the end, but their error
parameter. Vala does not support that at this point.
Introduced with 1df2c050ba29c84026a14e7ee23fa6bcd00b1044
See https://gitlab.gnome.org/GNOME/vala/issues/728
vapi/gio-2.0.vapi | 6 ++++--
vapi/metadata/Gio-2.0-custom.vala | 4 ----
vapi/metadata/Gio-2.0.metadata | 5 +++--
3 files changed, 7 insertions(+), 8 deletions(-)
---
diff --git a/vapi/gio-2.0.vapi b/vapi/gio-2.0.vapi
index 7c75ed664..7084bf0e5 100644
--- a/vapi/gio-2.0.vapi
+++ b/vapi/gio-2.0.vapi
@@ -4775,12 +4775,14 @@ namespace GLib {
[Version (since = "2.28")]
public delegate bool CancellableSourceFunc (GLib.Cancellable? cancellable = null);
[CCode (cheader_filename = "gio/gio.h", instance_pos = 6.9)]
- public delegate GLib.Variant DBusInterfaceGetPropertyFunc (GLib.DBusConnection connection, string
sender, string object_path, string interface_name, string property_name) throws GLib.Error;
+ [Version (since = "2.26")]
+ public delegate GLib.Variant DBusInterfaceGetPropertyFunc (GLib.DBusConnection connection, string
sender, string object_path, string interface_name, string property_name, out GLib.Error error);
[CCode (cheader_filename = "gio/gio.h", instance_pos = 7.9)]
[Version (since = "2.26")]
public delegate void DBusInterfaceMethodCallFunc (GLib.DBusConnection connection, string sender,
string object_path, string interface_name, string method_name, GLib.Variant parameters, owned
GLib.DBusMethodInvocation invocation);
[CCode (cheader_filename = "gio/gio.h", instance_pos = 7.9)]
- public delegate bool DBusInterfaceSetPropertyFunc (GLib.DBusConnection connection, string sender,
string object_path, string interface_name, string property_name, GLib.Variant value) throws GLib.Error;
+ [Version (since = "2.26")]
+ public delegate bool DBusInterfaceSetPropertyFunc (GLib.DBusConnection connection, string sender,
string object_path, string interface_name, string property_name, GLib.Variant value, out GLib.Error error);
[CCode (cheader_filename = "gio/gio.h", instance_pos = 3.9)]
[Version (since = "2.26")]
public delegate GLib.DBusMessage? DBusMessageFilterFunction (GLib.DBusConnection connection, owned
GLib.DBusMessage message, bool incoming);
diff --git a/vapi/metadata/Gio-2.0-custom.vala b/vapi/metadata/Gio-2.0-custom.vala
index d4965a1ba..b3cb7b95d 100644
--- a/vapi/metadata/Gio-2.0-custom.vala
+++ b/vapi/metadata/Gio-2.0-custom.vala
@@ -182,10 +182,6 @@ namespace GLib {
public delegate void TaskReadyCallback (GLib.Object? source_object, GLib.Task task);
[CCode (has_target = false, cname = "GSourceFunc")]
public delegate bool TaskSourceFunc (Task task);
- [CCode (cheader_filename = "gio/gio.h", instance_pos = 6.9)]
- public delegate GLib.Variant DBusInterfaceGetPropertyFunc (GLib.DBusConnection connection, string
sender, string object_path, string interface_name, string property_name) throws GLib.Error;
- [CCode (cheader_filename = "gio/gio.h", instance_pos = 7.9)]
- public delegate bool DBusInterfaceSetPropertyFunc (GLib.DBusConnection connection, string sender,
string object_path, string interface_name, string property_name, GLib.Variant value) throws GLib.Error;
[CCode (cheader_filename = "gio/gio.h", has_target = false, cname = "GSettingsBindGetMapping")]
public delegate bool SettingsBindGetMappingShared (GLib.Value value, GLib.Variant variant, void*
user_data);
diff --git a/vapi/metadata/Gio-2.0.metadata b/vapi/metadata/Gio-2.0.metadata
index 33aff2c90..d27471064 100644
--- a/vapi/metadata/Gio-2.0.metadata
+++ b/vapi/metadata/Gio-2.0.metadata
@@ -326,8 +326,9 @@ LoadableIcon
.load.type nullable
// Bug #666798: GIR parser should detect delegate types which throw errors
-DBusInterfaceGetPropertyFunc skip
-DBusInterfaceSetPropertyFunc skip
+// Issue #728: Support non-default error parameter position
+DBusInterfaceGetPropertyFunc.error out unowned=false
+DBusInterfaceSetPropertyFunc.error out unowned=false
// Bug #666799: symbols with moved-to annotations should be deprecated at the old locations
app_info*#function skip
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]