2002-08-08 Mike Kestner <mkestner@speakeasy.net>
* generator/Method.cs : s/GetType/GetGType. Don't generated static methods for interfaces. * glib/Object.cs : add GType prop * gnome/*.custom : s/Type/GType * parser/Gtk.metadata : rule to make TreeIter opaque * parser/gapi2xml.pl : handle interface methods properly * sample/Fifteen.cs : s/Type/GType svn path=/trunk/gtk-sharp/; revision=6556
This commit is contained in:
parent
71266c0337
commit
903349cd37
19 changed files with 1057 additions and 26 deletions
10
ChangeLog
10
ChangeLog
|
@ -1,3 +1,13 @@
|
||||||
|
2002-08-08 Mike Kestner <mkestner@speakeasy.net>
|
||||||
|
|
||||||
|
* generator/Method.cs : s/GetType/GetGType. Don't generated static
|
||||||
|
methods for interfaces.
|
||||||
|
* glib/Object.cs : add GType prop
|
||||||
|
* gnome/*.custom : s/Type/GType
|
||||||
|
* parser/Gtk.metadata : rule to make TreeIter opaque
|
||||||
|
* parser/gapi2xml.pl : handle interface methods properly
|
||||||
|
* sample/Fifteen.cs : s/Type/GType
|
||||||
|
|
||||||
2002-08-08 Mike Kestner <mkestner@speakeasy.net>
|
2002-08-08 Mike Kestner <mkestner@speakeasy.net>
|
||||||
|
|
||||||
* gdk/Event.cs : derived from Boxed, not Object.
|
* gdk/Event.cs : derived from Boxed, not Object.
|
||||||
|
|
|
@ -32,6 +32,8 @@ namespace GtkSharp.Generation {
|
||||||
parms = new Parameters (elem["parameters"]);
|
parms = new Parameters (elem["parameters"]);
|
||||||
this.container_type = container_type;
|
this.container_type = container_type;
|
||||||
this.name = elem.GetAttribute("name");
|
this.name = elem.GetAttribute("name");
|
||||||
|
if (name == "GetType")
|
||||||
|
name = "GetGType";
|
||||||
// override library - used in pixbuf API fixage
|
// override library - used in pixbuf API fixage
|
||||||
if (elem.HasAttribute ("library"))
|
if (elem.HasAttribute ("library"))
|
||||||
this.libname = elem.GetAttribute ("library");
|
this.libname = elem.GetAttribute ("library");
|
||||||
|
@ -206,6 +208,8 @@ namespace GtkSharp.Generation {
|
||||||
Method dup = null;
|
Method dup = null;
|
||||||
if (Name == "ToString")
|
if (Name == "ToString")
|
||||||
sw.Write("override ");
|
sw.Write("override ");
|
||||||
|
else if (Name == "GetGType" && container_type is ObjectGen)
|
||||||
|
sw.Write("new ");
|
||||||
else if (elem.HasAttribute("new_flag") || (container_type != null && (dup = container_type.GetMethodRecursively (Name)) != null) || (implementor != null && (dup = implementor.GetMethodRecursively (Name)) != null)) {
|
else if (elem.HasAttribute("new_flag") || (container_type != null && (dup = container_type.GetMethodRecursively (Name)) != null) || (implementor != null && (dup = implementor.GetMethodRecursively (Name)) != null)) {
|
||||||
if (dup != null && dup.parms != null)
|
if (dup != null && dup.parms != null)
|
||||||
dup.parms.CreateSignature (false);
|
dup.parms.CreateSignature (false);
|
||||||
|
@ -230,6 +234,9 @@ namespace GtkSharp.Generation {
|
||||||
if (!Initialize ())
|
if (!Initialize ())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (elem.HasAttribute("shared"))
|
||||||
|
return;
|
||||||
|
|
||||||
GenerateComments (sw);
|
GenerateComments (sw);
|
||||||
|
|
||||||
if (is_get || is_set)
|
if (is_get || is_set)
|
||||||
|
@ -295,6 +302,9 @@ namespace GtkSharp.Generation {
|
||||||
if (!Initialize ())
|
if (!Initialize ())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (implementor != null && elem.HasAttribute("shared"))
|
||||||
|
return;
|
||||||
|
|
||||||
/* we are generated by the get Method, if there is one */
|
/* we are generated by the get Method, if there is one */
|
||||||
if (is_set || is_get)
|
if (is_set || is_get)
|
||||||
{
|
{
|
||||||
|
|
1004
generator/gtkapi.xml
1004
generator/gtkapi.xml
File diff suppressed because it is too large
Load diff
|
@ -95,6 +95,20 @@ namespace GLib {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// GType Property
|
||||||
|
/// </summary>
|
||||||
|
///
|
||||||
|
/// <remarks>
|
||||||
|
/// The type associated with this object class.
|
||||||
|
/// </remarks>
|
||||||
|
|
||||||
|
public static int GType {
|
||||||
|
get {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Handle Property
|
/// Handle Property
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasBpath (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasBpath (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasClipgroup (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasClipgroup (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasEllipse (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasEllipse (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasLine (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasLine (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasPixbuf (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasPixbuf (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasPolygon (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasPolygon (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasRect (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasRect (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasRichText (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasRichText (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasText (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasText (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public CanvasWidget (Gnome.CanvasGroup group) : base (group, Type)
|
public CanvasWidget (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
// This code is inserted after the automatically generated code.
|
// This code is inserted after the automatically generated code.
|
||||||
//
|
//
|
||||||
|
|
||||||
public IconTextItem (Gnome.CanvasGroup group) : base (group, Type)
|
public IconTextItem (Gnome.CanvasGroup group) : base (group, GType)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1535,6 +1535,15 @@
|
||||||
</attribute>
|
</attribute>
|
||||||
</data>
|
</data>
|
||||||
</rule>
|
</rule>
|
||||||
|
<rule>
|
||||||
|
<class name="GtkTreeIter"/>
|
||||||
|
<data>
|
||||||
|
<attribute target="class">
|
||||||
|
<name>opaque</name>
|
||||||
|
<value>1</value>
|
||||||
|
</attribute>
|
||||||
|
</data>
|
||||||
|
</rule>
|
||||||
<rule>
|
<rule>
|
||||||
<class name="GtkTreeModel">
|
<class name="GtkTreeModel">
|
||||||
<method>IterNChildren</method>
|
<method>IterNChildren</method>
|
||||||
|
|
|
@ -235,7 +235,8 @@ foreach $type (sort(keys(%ifaces))) {
|
||||||
|
|
||||||
$ifacecnt++;
|
$ifacecnt++;
|
||||||
$iface_el = addNameElem($ns_elem, 'interface', $inst, $ns);
|
$iface_el = addNameElem($ns_elem, 'interface', $inst, $ns);
|
||||||
addFuncElems($iface_el, $inst);
|
|
||||||
|
$elem_table{lc($inst)} = $iface_el;
|
||||||
|
|
||||||
$classdef = $sdefs{$1} if ($ifacetype =~ /struct\s+(\w+)/);
|
$classdef = $sdefs{$1} if ($ifacetype =~ /struct\s+(\w+)/);
|
||||||
if ($initfunc) {
|
if ($initfunc) {
|
||||||
|
|
|
@ -185,7 +185,7 @@ public class BoardPiece : Gnome.CanvasGroup
|
||||||
public static bool Debug = false;
|
public static bool Debug = false;
|
||||||
|
|
||||||
public BoardPiece (CanvasGroup group, BoardPiece [] board, int x, int y, int i)
|
public BoardPiece (CanvasGroup group, BoardPiece [] board, int x, int y, int i)
|
||||||
: base (group, CanvasGroup.Type)
|
: base (group, CanvasGroup.GType)
|
||||||
{
|
{
|
||||||
this.X = (x * PIECE_SIZE);
|
this.X = (x * PIECE_SIZE);
|
||||||
this.Y = (y * PIECE_SIZE);
|
this.Y = (y * PIECE_SIZE);
|
||||||
|
|
|
@ -1535,6 +1535,15 @@
|
||||||
</attribute>
|
</attribute>
|
||||||
</data>
|
</data>
|
||||||
</rule>
|
</rule>
|
||||||
|
<rule>
|
||||||
|
<class name="GtkTreeIter"/>
|
||||||
|
<data>
|
||||||
|
<attribute target="class">
|
||||||
|
<name>opaque</name>
|
||||||
|
<value>1</value>
|
||||||
|
</attribute>
|
||||||
|
</data>
|
||||||
|
</rule>
|
||||||
<rule>
|
<rule>
|
||||||
<class name="GtkTreeModel">
|
<class name="GtkTreeModel">
|
||||||
<method>IterNChildren</method>
|
<method>IterNChildren</method>
|
||||||
|
|
Loading…
Reference in a new issue