From 556ee78ac74544bb8979d95f66ee425748bfc03a Mon Sep 17 00:00:00 2001 From: triton Date: Wed, 29 May 2013 19:27:01 +0100 Subject: [PATCH] Collect the get/set methods used in properties so that we generate the needed internal function declarations. --- src/Generator/Generators/CSharp/CSharpTextTemplate.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs index 7cafb56d..1af20317 100644 --- a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs +++ b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs @@ -365,6 +365,15 @@ namespace CppSharp.Generators.CSharp functions.Add(method); } + foreach (var prop in @class.Properties) + { + if (prop.GetMethod != null) + functions.Add(prop.GetMethod); + + if (prop.SetMethod != null) + functions.Add(prop.SetMethod); + } + foreach (var function in functions) { NewLineIfNeeded();