[gnome-builder/wip/libide: 131/153] libide: add GType for IdeDiagnosticSeverity



commit 4371fde8c7a61832e4bf19eec9b2e13118854f68
Author: Christian Hergert <christian hergert me>
Date:   Thu Feb 12 11:28:33 2015 -0800

    libide: add GType for IdeDiagnosticSeverity

 libide/ide-diagnostic.c |   24 ++++++++++++++++++++++++
 1 files changed, 24 insertions(+), 0 deletions(-)
---
diff --git a/libide/ide-diagnostic.c b/libide/ide-diagnostic.c
index f2e7886..d758c99 100644
--- a/libide/ide-diagnostic.c
+++ b/libide/ide-diagnostic.c
@@ -81,3 +81,27 @@ _ide_diagnostic_new (IdeDiagnosticSeverity  severity,
 
   return ret;
 }
+
+GType
+ide_diagnostic_severity_get_type (void)
+{
+  static gsize type_id;
+
+  if (g_once_init_enter (&type_id))
+    {
+      gsize _type_id;
+      static const GEnumValue values[] = {
+        { IDE_DIAGNOSTIC_IGNORED, "IDE_DIAGNOSTIC_IGNORED", "IGNORED" },
+        { IDE_DIAGNOSTIC_NOTE, "IDE_DIAGNOSTIC_NOTE", "NOTE" },
+        { IDE_DIAGNOSTIC_WARNING, "IDE_DIAGNOSTIC_WARNING", "WARNING" },
+        { IDE_DIAGNOSTIC_ERROR, "IDE_DIAGNOSTIC_ERROR", "ERROR" },
+        { IDE_DIAGNOSTIC_FATAL, "IDE_DIAGNOSTIC_FATAL", "FATAL" },
+        { 0 }
+      };
+
+      _type_id = g_enum_register_static ("IdeDiagnosticSeverity", values);
+      g_once_init_leave (&type_id, _type_id);
+    }
+
+  return type_id;
+}


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