[vala] libnotify: Switch to GIR
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] libnotify: Switch to GIR
- Date: Thu, 28 Nov 2013 08:38:33 +0000 (UTC)
commit 4991b8f799198b5ad517cc75024e5429453eef10
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Thu Nov 28 09:28:19 2013 +0100
libnotify: Switch to GIR
vapi/Makefile.am | 4 +-
vapi/libnotify.deps | 2 -
vapi/libnotify.vapi | 34 +++--
vapi/metadata/Notify-0.7.metadata | 5 +
vapi/packages/libnotify/libnotify.deps | 4 -
vapi/packages/libnotify/libnotify.files | 2 -
vapi/packages/libnotify/libnotify.gi | 229 ---------------------------
vapi/packages/libnotify/libnotify.metadata | 11 --
vapi/packages/libnotify/libnotify.namespace | 1 -
9 files changed, 28 insertions(+), 264 deletions(-)
---
diff --git a/vapi/Makefile.am b/vapi/Makefile.am
index 0031839..0ceece7 100644
--- a/vapi/Makefile.am
+++ b/vapi/Makefile.am
@@ -343,7 +343,6 @@ GIDL_BINDINGS = \
libgnome-menu \
libgnomeui-2.0 \
libgsf-1 \
- libnotify \
liboobs-1 \
librsvg-2.0 \
libsexy \
@@ -398,6 +397,7 @@ GIR_BINDINGS = \
json-glib-1.0 \
libgdata \
libgnome-menu-3.0 \
+ libnotify \
libpeas-1.0 \
libpeas-gtk-1.0 \
libsoup-2.4 \
@@ -677,7 +677,7 @@ libgsf-1:
$(GENVAPI) --library $(srcdir)/libgsf-1 $(PACKAGESDIR)/libgsf-1/libgsf-1-custom.vala
$(PACKAGESDIR)/libgsf-1/libgsf-1.gi
libnotify:
- $(GENVAPI) --library $(srcdir)/libnotify $(PACKAGESDIR)/libnotify/libnotify.gi
+ $(GENVAPI) --library $(srcdir)/libnotify --pkg gdk-pixbuf-2.0 --pkg gio-2.0 --metadatadir
$(METADATADIR) $(GIRDIR)/Notify-0.7.gir
liboobs-1:
$(GENVAPI) --library $(srcdir)/liboobs-1 $(PACKAGESDIR)/liboobs-1/liboobs-1.gi
diff --git a/vapi/libnotify.deps b/vapi/libnotify.deps
index f3d91f7..f162e5b 100644
--- a/vapi/libnotify.deps
+++ b/vapi/libnotify.deps
@@ -1,4 +1,2 @@
-atk
-cairo
gio-2.0
gdk-pixbuf-2.0
diff --git a/vapi/libnotify.vapi b/vapi/libnotify.vapi
index c5a6751..9c44b6b 100644
--- a/vapi/libnotify.vapi
+++ b/vapi/libnotify.vapi
@@ -1,7 +1,8 @@
/* libnotify.vapi generated by vapigen, do not modify. */
+[CCode (cprefix = "Notify", gir_namespace = "Notify", gir_version = "0.7", lower_case_cprefix = "notify_")]
namespace Notify {
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", type_id = "notify_notification_get_type ()")]
public class Notification : GLib.Object {
[CCode (has_construct_function = false)]
public Notification (string summary, string? body, string? icon);
@@ -12,19 +13,26 @@ namespace Notify {
public int get_closed_reason ();
public void set_app_name (string app_name);
public void set_category (string category);
- public void set_hint (string key, GLib.Variant value);
- public void set_hint_byte (string key, uchar value);
- public void set_hint_byte_array (string key, uchar[] value, size_t len);
+ public void set_hint (string key, GLib.Variant? value);
+ [Deprecated (since = "0.6.")]
+ public void set_hint_byte (string key, [CCode (type = "guchar")] uchar value);
+ [Deprecated (since = "0.6.")]
+ public void set_hint_byte_array (string key, [CCode (array_length = false, type = "const
guchar*")] uchar[] value, size_t len);
+ [Deprecated (since = "0.6.")]
public void set_hint_double (string key, double value);
+ [Deprecated (since = "0.6.")]
public void set_hint_int32 (string key, int value);
+ [Deprecated (since = "0.6.")]
public void set_hint_string (string key, string value);
+ [Deprecated (since = "0.6.")]
public void set_hint_uint32 (string key, uint value);
+ [Deprecated]
public void set_icon_from_pixbuf (Gdk.Pixbuf icon);
public void set_image_from_pixbuf (Gdk.Pixbuf pixbuf);
public void set_timeout (int timeout);
public void set_urgency (Notify.Urgency urgency);
public bool show () throws GLib.Error;
- public bool update (string summary, string body, string icon);
+ public bool update (string summary, string? body, string? icon);
[NoAccessorMethod]
public string app_name { owned get; set; }
[NoAccessorMethod]
@@ -38,30 +46,30 @@ namespace Notify {
public string summary { owned get; set construct; }
public virtual signal void closed ();
}
- [CCode (cheader_filename = "libnotify/notify.h", cprefix = "NOTIFY_URGENCY_")]
+ [CCode (cheader_filename = "libnotify/notify.h", cprefix = "NOTIFY_URGENCY_", has_type_id = false)]
public enum Urgency {
LOW,
NORMAL,
CRITICAL
}
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", instance_pos = 2.9)]
public delegate void ActionCallback (Notify.Notification notification, string action);
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", cname = "NOTIFY_EXPIRES_DEFAULT")]
public const int EXPIRES_DEFAULT;
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", cname = "NOTIFY_EXPIRES_NEVER")]
public const int EXPIRES_NEVER;
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", cname = "NOTIFY_VERSION_MAJOR")]
public const int VERSION_MAJOR;
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", cname = "NOTIFY_VERSION_MICRO")]
public const int VERSION_MICRO;
- [CCode (cheader_filename = "libnotify/notify.h")]
+ [CCode (cheader_filename = "libnotify/notify.h", cname = "NOTIFY_VERSION_MINOR")]
public const int VERSION_MINOR;
[CCode (cheader_filename = "libnotify/notify.h")]
public static unowned string get_app_name ();
[CCode (cheader_filename = "libnotify/notify.h")]
public static GLib.List<string> get_server_caps ();
[CCode (cheader_filename = "libnotify/notify.h")]
- public static bool get_server_info (out unowned string ret_name, out unowned string ret_vendor, out
unowned string ret_version, out unowned string ret_spec_version);
+ public static bool get_server_info (out string ret_name, out string ret_vendor, out string
ret_version, out string ret_spec_version);
[CCode (cheader_filename = "libnotify/notify.h")]
public static bool init (string app_name);
[CCode (cheader_filename = "libnotify/notify.h")]
diff --git a/vapi/metadata/Notify-0.7.metadata b/vapi/metadata/Notify-0.7.metadata
new file mode 100644
index 0000000..edfa4e5
--- /dev/null
+++ b/vapi/metadata/Notify-0.7.metadata
@@ -0,0 +1,5 @@
+* cheader_filename="libnotify/notify.h"
+
+Notification
+ .set_hint_byte.value type="uchar"
+ .set_hint_byte_array.value type="uchar[]"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]