generator: Fix handle being passed when type is a struct

A static getter method would always generate a Handle parameter even
though some types do not have a Handle, for example structs.

Closes issue #99.

Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
This commit is contained in:
Stephan Sundermann 2014-03-18 02:16:05 +01:00 committed by Bertrand Lorentz
parent 06b966beef
commit 0563af1c25

View file

@ -243,7 +243,7 @@ namespace GtkSharp.Generation {
return;
else {
is_set = false;
call = "(Handle, " + Body.GetCallString (false) + ")";
call = "(" + (IsStatic ? "" : container_type.CallByName () + (parms.Count > 0 ? ", " : "")) + Body.GetCallString (false) + ")";
comp = null;
}
}