diff options
author | Rico Tzschichholz <ricotz@ubuntu.com> | 2022-08-09 08:13:38 +0200 |
---|---|---|
committer | Rico Tzschichholz <ricotz@ubuntu.com> | 2022-08-09 08:44:28 +0200 |
commit | edd33896e11ee319e82b7678464b249942f9dbfc (patch) | |
tree | b1a1b0aac199ec3c45e7e01f820dec0048a923d5 /vapi | |
parent | 03725ca4485afa5b87dd00098e8b03d3820dd06c (diff) | |
download | vala-edd33896e11ee319e82b7678464b249942f9dbfc.tar.gz |
atspi-2: Fix a few binding errors
Diffstat (limited to 'vapi')
-rw-r--r-- | vapi/atspi-2.vapi | 24 | ||||
-rw-r--r-- | vapi/metadata/Atspi-2.0.metadata | 14 |
2 files changed, 27 insertions, 11 deletions
diff --git a/vapi/atspi-2.vapi b/vapi/atspi-2.vapi index 01564cf9b..3b695957d 100644 --- a/vapi/atspi-2.vapi +++ b/vapi/atspi-2.vapi @@ -91,7 +91,7 @@ namespace Atspi { [CCode (has_construct_function = false)] protected Application (); } - [CCode (cheader_filename = "atspi/atspi.h", type_id = "atspi_device_get_type ()")] + [CCode (cheader_filename = "atspi/atspi-device.h", type_id = "atspi_device_get_type ()")] public class Device : GLib.Object { [CCode (has_construct_function = false)] public Device (); @@ -108,7 +108,7 @@ namespace Atspi { public virtual void ungrab_keyboard (); public virtual void unmap_modifier (int keycode); } - [CCode (cheader_filename = "atspi/atspi.h", type_id = "atspi_device_legacy_get_type ()")] + [CCode (cheader_filename = "atspi/atspi-device-legacy.h", type_id = "atspi_device_legacy_get_type ()")] public class DeviceLegacy : Atspi.Device { [CCode (has_construct_function = false)] public DeviceLegacy (); @@ -126,7 +126,7 @@ namespace Atspi { [CCode (has_construct_function = false)] public DeviceListener.simple ([CCode (destroy_notify_pos = 1.1)] owned Atspi.DeviceListenerSimpleCB callback); } - [CCode (cheader_filename = "atspi/atspi.h", type_id = "atspi_device_x11_get_type ()")] + [CCode (cheader_filename = "atspi/atspi-device-x11.h", type_id = "atspi_device_x11_get_type ()")] public class DeviceX11 : Atspi.Device { [CCode (has_construct_function = false)] public DeviceX11 (); @@ -145,9 +145,8 @@ namespace Atspi { } [CCode (cheader_filename = "atspi/atspi.h", type_id = "atspi_event_listener_get_type ()")] public class EventListener : GLib.Object { - public weak Atspi.EventListenerCB callback; - public weak GLib.DestroyNotify cb_destroyed; - public void* user_data; + [CCode (delegate_target_cname = "user_data", destroy_notify_cname = "cb_destroyed")] + public Atspi.EventListenerCB callback; [CCode (has_construct_function = false)] public EventListener (owned Atspi.EventListenerCB callback); public bool deregister (string event_type) throws GLib.Error; @@ -461,9 +460,12 @@ namespace Atspi { } [CCode (cheader_filename = "atspi/atspi.h", has_type_id = false)] public struct KeySet { - public uint keysyms; - public ushort keycodes; - public weak string keystrings; + [CCode (array_length_cname = "len", array_length_type = "gshort")] + public weak uint[] keysyms; + [CCode (array_length_cname = "len", array_length_type = "gshort")] + public weak ushort[] keycodes; + [CCode (array_length_cname = "len", array_length_type = "gshort")] + public weak string[] keystrings; public short len; } [CCode (cheader_filename = "atspi/atspi.h", cprefix = "ATSPI_CACHE_", type_id = "atspi_cache_get_type ()")] @@ -822,9 +824,9 @@ namespace Atspi { PARAGRAPH } [CCode (cheader_filename = "atspi/atspi.h", instance_pos = 1.9)] - public delegate bool DeviceListenerCB (owned Atspi.DeviceEvent stroke); + public delegate bool DeviceListenerCB (Atspi.DeviceEvent stroke); [CCode (cheader_filename = "atspi/atspi.h", has_target = false)] - public delegate bool DeviceListenerSimpleCB (owned Atspi.DeviceEvent stroke); + public delegate bool DeviceListenerSimpleCB (Atspi.DeviceEvent stroke); [CCode (cheader_filename = "atspi/atspi.h", instance_pos = 1.9)] public delegate void EventListenerCB (owned Atspi.Event event); [CCode (cheader_filename = "atspi/atspi.h", has_target = false)] diff --git a/vapi/metadata/Atspi-2.0.metadata b/vapi/metadata/Atspi-2.0.metadata index eec213c7a..6265da786 100644 --- a/vapi/metadata/Atspi-2.0.metadata +++ b/vapi/metadata/Atspi-2.0.metadata @@ -1,11 +1,25 @@ Application.bus skip KeystrokeListener skip +Device cheader_filename="atspi/atspi-device.h" +DeviceLegacy cheader_filename="atspi/atspi-device-legacy.h" +DeviceX11 cheader_filename="atspi/atspi-device-x11.h" + DeviceEvent struct DeviceListener .new_simple skip=false +DeviceListenerCB.stroke owned=false +DeviceListenerSimpleCB.stroke owned=false EventListener .*_no_data skip=false .new_simple skip=false + .callback unowned=false delegate_target_cname="user_data" destroy_notify_cname="cb_destroyed" + .cb_destroyed skip + .user_data skip + +KeySet + .keysyms array array_length_field="len" + .keycodes array array_length_field="len" + .keystrings array array_length_field="len" |