[perl-Glib-Object-Introspection] Register error domains



commit bafb1b0d7bf002aec3dde994e6f6270c828bcf8c
Author: Torsten SchÃnfeld <kaffeetisch gmx de>
Date:   Thu Feb 14 21:13:55 2013 +0100

    Register error domains
    
    So that you can use the Glib::Error magic.

 GObjectIntrospection.xs |    9 +++++++++
 NEWS                    |    5 +++++
 2 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/GObjectIntrospection.xs b/GObjectIntrospection.xs
index e22ba31..5309e18 100644
--- a/GObjectIntrospection.xs
+++ b/GObjectIntrospection.xs
@@ -448,6 +448,15 @@ _register_types (class, namespace, package)
                    case GI_INFO_TYPE_ENUM:
                    case GI_INFO_TYPE_FLAGS:
                        gperl_register_fundamental (type, full_package);
+#if GI_CHECK_VERSION (1, 29, 17)
+                       {
+                               const gchar *domain = g_enum_info_get_error_domain (info);
+                               if (domain) {
+                                       gperl_register_error_domain (g_quark_from_string (domain),
+                                                                    type, full_package);
+                               }
+                       }
+#endif
                        break;
 
                    default:
diff --git a/NEWS b/NEWS
index 52144c6..de1b872 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,8 @@
+Overview of changes in Glib::Object::Introspection <next>
+========================================================
+
+* Register error domains.
+
 Overview of changes in Glib::Object::Introspection 0.014
 ========================================================
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]