From c54fcdf724e473bc6a810ee8e271c57f1b8807d1 Mon Sep 17 00:00:00 2001 From: the_fiddler Date: Wed, 31 Oct 2007 17:42:29 +0000 Subject: [PATCH] Fixed a regression where pure IntPtr parameters (size etc etc) obtained 'object' overloads. --- Source/Bind/Structures/Delegate.cs | 6 ++---- Source/Bind/Structures/Parameter.cs | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/Source/Bind/Structures/Delegate.cs b/Source/Bind/Structures/Delegate.cs index fc9c0a80..f68a97e9 100644 --- a/Source/Bind/Structures/Delegate.cs +++ b/Source/Bind/Structures/Delegate.cs @@ -485,10 +485,8 @@ namespace Bind.Structures protected virtual void TranslateParameters() { - //if (this.Name.Contains("VertexPointer")) - //{ - // Console.WriteLine(); - //} + // Iterates through all parameters, calling the Parameter.Translate() function. + for (int i = 0; i < Parameters.Count; i++) { Parameters[i] = Parameter.Translate(Parameters[i], this.Category); diff --git a/Source/Bind/Structures/Parameter.cs b/Source/Bind/Structures/Parameter.cs index 67ba5b68..4a87298c 100644 --- a/Source/Bind/Structures/Parameter.cs +++ b/Source/Bind/Structures/Parameter.cs @@ -345,7 +345,7 @@ namespace Bind.Structures // p.CurrentType = CSTypes[p.CurrentType]; // Translate pointer parameters - if (p.Pointer || p.CurrentType == "IntPtr") + if (p.Pointer)/* || p.CurrentType == "IntPtr")*/ { p.WrapperType = WrapperTypes.ArrayParameter; @@ -360,7 +360,7 @@ namespace Bind.Structures p.Pointer = false; p.WrapperType = WrapperTypes.None; } - else if (p.CurrentType.ToLower().Contains("void") || p.CurrentType.Contains("IntPtr")) + else if (p.CurrentType.ToLower().Contains("void")) /*|| p.CurrentType.Contains("IntPtr"))*/ { p.CurrentType = "IntPtr"; p.Pointer = false;