diff --git a/glib/EnumWrapper.cs b/glib/EnumWrapper.cs deleted file mode 100644 index 80b4afecc..000000000 --- a/glib/EnumWrapper.cs +++ /dev/null @@ -1,42 +0,0 @@ -// EnumWrapper.cs - Class to hold arbitrary glib enums -// -// Author: Rachel Hestilow -// -// Copyright (c) 2002 Rachel Hestilow -// -// This program is free software; you can redistribute it and/or -// modify it under the terms of version 2 of the Lesser GNU General -// Public License as published by the Free Software Foundation. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this program; if not, write to the -// Free Software Foundation, Inc., 59 Temple Place - Suite 330, -// Boston, MA 02111-1307, USA. - - -namespace GLib { - - using System; - using System.Runtime.InteropServices; - - [Obsolete ("Replaced by direct enum type casts to/from GLib.Value")] - public class EnumWrapper { - int val; - public bool flags; - - public EnumWrapper (int val, bool flags) { - this.val = val; - this.flags = flags; - } - - public static explicit operator int (EnumWrapper wrap) { - return wrap.val; - } - } -} - diff --git a/glib/Makefile.am b/glib/Makefile.am index 5755f8586..4e4aad34f 100644 --- a/glib/Makefile.am +++ b/glib/Makefile.am @@ -25,7 +25,6 @@ sources = \ DefaultSignalHandlerAttribute.cs \ DelegateWrapper.cs \ DestroyNotify.cs \ - EnumWrapper.cs \ ExceptionManager.cs \ FileUtils.cs \ GException.cs \ diff --git a/glib/Value.cs b/glib/Value.cs index 6c29cd65b..d1465dac3 100755 --- a/glib/Value.cs +++ b/glib/Value.cs @@ -110,19 +110,6 @@ namespace GLib { g_value_set_uint64 (ref this, val); } - [Obsolete ("Replaced by Value(object) constructor")] - public Value (EnumWrapper wrap, string type_name) - { - type = IntPtr.Zero; - pad1 = new Padding (); - pad2 = new Padding (); - g_value_init (ref this, GType.FromName (type_name).Val); - if (wrap.flags) - g_value_set_flags (ref this, (uint) (int) wrap); - else - g_value_set_enum (ref this, (int) wrap); - } - public Value (float val) : this (GType.Float) { g_value_set_float (ref this, val); @@ -177,19 +164,6 @@ namespace GLib { InitForProperty (obj, prop_name); } - [Obsolete] - public Value (GLib.Object obj, string prop_name, EnumWrapper wrap) - { - type = IntPtr.Zero; - pad1 = new Padding (); - pad2 = new Padding (); - InitForProperty (obj.NativeType, prop_name); - if (wrap.flags) - g_value_set_flags (ref this, (uint) (int) wrap); - else - g_value_set_enum (ref this, (int) wrap); - } - [Obsolete] public Value (IntPtr obj, string prop_name, Opaque val) { @@ -277,15 +251,6 @@ namespace GLib { return g_value_get_uint64 (ref val); } - [Obsolete ("Replaced by Enum cast")] - public static explicit operator EnumWrapper (Value val) - { - if (val.HoldsFlags) - return new EnumWrapper ((int)g_value_get_flags (ref val), true); - else - return new EnumWrapper (g_value_get_enum (ref val), false); - } - public static explicit operator Enum (Value val) { if (val.HoldsFlags)