diff --git a/glib/Variant.cs b/glib/Variant.cs index 9ff39f670..f12283861 100644 --- a/glib/Variant.cs +++ b/glib/Variant.cs @@ -59,6 +59,13 @@ namespace GLib { this.handle = g_variant_ref_sink (handle); } + [DllImport (Global.GLibNativeDll, CallingConvention = CallingConvention.Cdecl)] + static extern IntPtr g_variant_new_variant (IntPtr val); + + public static Variant NewVariant (Variant val) { + return new Variant (g_variant_new_variant (val.Handle)); + } + [DllImport (Global.GLibNativeDll, CallingConvention = CallingConvention.Cdecl)] static extern IntPtr g_variant_new_boolean (bool val);