mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2024-12-24 00:05:38 +00:00
2004-04-16 Rachel Hestilow <rachel@nullenvoid.com>
* generator/GObjectGen.cs: Added new generatable to handle plain GObjects the same way we do subclasses. * generator/ManualGen.cs: Make FromNative/FromNativeReturn virtual to allow overriding. * generator/SymbolTable.cs: Use GObjectGen instead of ManualGen for GObject. * generator/Makefile.am: Add GObjectGen.cs. svn path=/trunk/gtk-sharp/; revision=25651
This commit is contained in:
parent
ed507416b2
commit
aee0a1f894
10
ChangeLog
10
ChangeLog
|
@ -1,3 +1,13 @@
|
|||
2004-04-16 Rachel Hestilow <rachel@nullenvoid.com>
|
||||
|
||||
* generator/GObjectGen.cs: Added new generatable to handle
|
||||
plain GObjects the same way we do subclasses.
|
||||
* generator/ManualGen.cs: Make FromNative/FromNativeReturn virtual
|
||||
to allow overriding.
|
||||
* generator/SymbolTable.cs: Use GObjectGen instead of
|
||||
ManualGen for GObject.
|
||||
* generator/Makefile.am: Add GObjectGen.cs.
|
||||
|
||||
2004-04-16 Boyd Timothy <btimothy@novell.com>
|
||||
|
||||
* gdk/Global.custom : properties to expose window manager spec
|
||||
|
|
22
generator/GObjectGen.cs
Normal file
22
generator/GObjectGen.cs
Normal file
|
@ -0,0 +1,22 @@
|
|||
// GtkSharp.Generation.GObjectGen.cs - The GObject generatable
|
||||
//
|
||||
// Note: This generatable only handles GObject* values. GObject subclasses
|
||||
// are handled by ObjectGen.
|
||||
//
|
||||
// Author: Rachel Hestilow <rachel@nullenvoid.com>
|
||||
//
|
||||
// (c) 2004 Rachel Hestilow
|
||||
|
||||
namespace GtkSharp.Generation {
|
||||
|
||||
public class GObjectGen : ManualGen {
|
||||
|
||||
public GObjectGen () : base ("GObject", "GLib.Object") {}
|
||||
|
||||
public override string FromNative(string var)
|
||||
{
|
||||
return "GLib.Object.GetObject (" + var + ")";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -21,6 +21,7 @@ sources = \
|
|||
Field.cs \
|
||||
GenBase.cs \
|
||||
GenerationInfo.cs \
|
||||
GObjectGen.cs \
|
||||
IGeneratable.cs \
|
||||
ImportSignature.cs \
|
||||
InterfaceGen.cs \
|
||||
|
|
|
@ -68,12 +68,12 @@ namespace GtkSharp.Generation {
|
|||
return var_name + "." + handle;
|
||||
}
|
||||
|
||||
public string FromNative(string var)
|
||||
public virtual string FromNative(string var)
|
||||
{
|
||||
return "new " + QualifiedName + "(" + var + ")";
|
||||
}
|
||||
|
||||
public string FromNativeReturn(string var)
|
||||
public virtual string FromNativeReturn(string var)
|
||||
{
|
||||
return FromNative (var);
|
||||
}
|
||||
|
|
|
@ -94,7 +94,7 @@ namespace GtkSharp.Generation {
|
|||
AddType (new ManualGen ("GSList", "GLib.SList"));
|
||||
AddType (new ManualGen ("GList", "GLib.List"));
|
||||
AddType (new ByRefGen ("GValue", "GLib.Value"));
|
||||
AddType (new ManualGen ("GObject", "GLib.Object"));
|
||||
AddType (new GObjectGen ());
|
||||
}
|
||||
|
||||
public void AddType (IGeneratable gen)
|
||||
|
|
Loading…
Reference in a new issue