[vala] gdk-3.0: Fix gdk_window_destroy binding again
- From: JÃrg Billeter <juergbi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] gdk-3.0: Fix gdk_window_destroy binding again
- Date: Thu, 23 Feb 2012 15:13:53 +0000 (UTC)
commit cb410b6a2edaf032dba61339f2b5c6d1aa55d5aa
Author: JÃrg Billeter <j bitron ch>
Date: Thu Feb 23 16:09:57 2012 +0100
gdk-3.0: Fix gdk_window_destroy binding again
vala/valagirparser.vala | 6 +++++-
vapi/gdk-3.0.vapi | 7 +++++++
vapi/metadata/Gdk-3.0.metadata | 1 +
3 files changed, 13 insertions(+), 1 deletions(-)
---
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index 1fc2185..530470c 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -69,7 +69,8 @@ public class Vala.GirParser : CodeVisitor {
CLOSURE,
CPREFIX,
LOWER_CASE_CPREFIX,
- ERRORDOMAIN;
+ ERRORDOMAIN,
+ DESTROYS_INSTANCE;
public static ArgumentType? from_string (string name) {
var enum_class = (EnumClass) typeof(ArgumentType).class_ref ();
@@ -799,6 +800,9 @@ public class Vala.GirParser : CodeVisitor {
}
}
if (!(m is CreationMethod)) {
+ if (metadata.has_argument (ArgumentType.DESTROYS_INSTANCE)) {
+ m.set_attribute ("DestroysInstance", true);
+ }
// merge custom vfunc
if (metadata.has_argument (ArgumentType.VFUNC_NAME)) {
var vfunc = parent.lookup (metadata.get_string (ArgumentType.VFUNC_NAME));
diff --git a/vapi/gdk-3.0.vapi b/vapi/gdk-3.0.vapi
index eb99918..3d708c9 100644
--- a/vapi/gdk-3.0.vapi
+++ b/vapi/gdk-3.0.vapi
@@ -4864,6 +4864,7 @@ namespace Gdk {
public void coords_to_parent (double x, double y, out double parent_x, out double parent_y);
public Cairo.Surface create_similar_surface (Cairo.Content content, int width, int height);
public void deiconify ();
+ [DestroysInstance]
public void destroy ();
public void enable_synchronized_configure ();
public void end_paint ();
@@ -5732,6 +5733,12 @@ namespace Gdk {
public delegate Gdk.FilterReturn FilterFunc (Gdk.XEvent xevent, Gdk.Event event);
[CCode (cheader_filename = "gdk/gdk.h", instance_pos = 1.9)]
public delegate bool WindowChildFunc (Gdk.Window window);
+ [CCode (cheader_filename = "gdk/gdk.h", cname = "GDK_BUTTON_MIDDLE")]
+ public const int BUTTON_MIDDLE;
+ [CCode (cheader_filename = "gdk/gdk.h", cname = "GDK_BUTTON_PRIMARY")]
+ public const int BUTTON_PRIMARY;
+ [CCode (cheader_filename = "gdk/gdk.h", cname = "GDK_BUTTON_SECONDARY")]
+ public const int BUTTON_SECONDARY;
[CCode (cheader_filename = "gdk/gdk.h", cname = "GDK_CURRENT_TIME")]
public const int CURRENT_TIME;
[CCode (cheader_filename = "gdk/gdk.h", cname = "GDK_MAX_TIMECOORD_AXES")]
diff --git a/vapi/metadata/Gdk-3.0.metadata b/vapi/metadata/Gdk-3.0.metadata
index febd44b..c7368be 100644
--- a/vapi/metadata/Gdk-3.0.metadata
+++ b/vapi/metadata/Gdk-3.0.metadata
@@ -48,6 +48,7 @@ Device
.grab_info_libgtk_only skip
Display.open_default_libgtk_only skip=false
Window
+ .destroy destroys_instance
.destroy_notify skip
synthesize_window_state skip
EventMotion
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]