2001-10-25 Mike Kestner <mkestner@speakeasy.net>
* glib/Object.cs : Added Get|SetProperty methods for Object properties. svn path=/trunk/gtk-sharp/; revision=1204
This commit is contained in:
parent
d7df5fa0ca
commit
bdec55ab35
2 changed files with 38 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2001-10-25 Mike Kestner <mkestner@speakeasy.net>
|
||||
|
||||
* glib/Object.cs : Added Get|SetProperty methods for Object
|
||||
properties.
|
||||
|
||||
2001-10-25 Mike Kestner <mkestner@speakeasy.net>
|
||||
|
||||
* codegen/get-props-from-source.pl : Temporary (possibly) defs
|
||||
|
|
|
@ -200,6 +200,23 @@ namespace GLib {
|
|||
out val, new IntPtr (0));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// GetProperty Method
|
||||
/// </summary>
|
||||
///
|
||||
/// <remarks>
|
||||
/// Accesses an Object Property.
|
||||
/// </remarks>
|
||||
|
||||
public void GetProperty (String name, out GLib.Object val)
|
||||
{
|
||||
IntPtr obj;
|
||||
g_object_get (RawObject,
|
||||
Marshal.StringToHGlobalAnsi (name),
|
||||
out obj, new IntPtr (0));
|
||||
val = GLib.Object.GetObject (obj);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// SetProperty Method
|
||||
/// </summary>
|
||||
|
@ -261,6 +278,22 @@ namespace GLib {
|
|||
val, new IntPtr (0));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// SetProperty Method
|
||||
/// </summary>
|
||||
///
|
||||
/// <remarks>
|
||||
/// Changes the value of an Object Property.
|
||||
/// </remarks>
|
||||
|
||||
public void SetProperty (String name, GLib.Object val)
|
||||
{
|
||||
g_object_set (RawObject,
|
||||
Marshal.StringToHGlobalAnsi (name),
|
||||
val.Handle, new IntPtr (0));
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
[DllImport("gtk-1.3.dll")]
|
||||
static extern void g_object_set_data_full (
|
||||
|
|
Loading…
Reference in a new issue