mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2024-09-09 00:13:20 +02:00
2009-01-09 Mike Kestner <mkestner@novell.com>
* glib/Opaque.cs (GetOpaque): return null for IntPtr.Zero. svn path=/trunk/gtk-sharp/; revision=123140
This commit is contained in:
parent
dc069c7338
commit
33849fd085
@ -1,3 +1,7 @@
|
|||||||
|
2009-01-09 Mike Kestner <mkestner@novell.com>
|
||||||
|
|
||||||
|
* glib/Opaque.cs (GetOpaque): return null for IntPtr.Zero.
|
||||||
|
|
||||||
2009-01-09 Mike Kestner <mkestner@novell.com>
|
2009-01-09 Mike Kestner <mkestner@novell.com>
|
||||||
|
|
||||||
* configure.in.in: don't hardcode CC when cross-compiling.
|
* configure.in.in: don't hardcode CC when cross-compiling.
|
||||||
|
@ -44,6 +44,9 @@ namespace GLib {
|
|||||||
|
|
||||||
public static Opaque GetOpaque (IntPtr o, Type type, bool owned)
|
public static Opaque GetOpaque (IntPtr o, Type type, bool owned)
|
||||||
{
|
{
|
||||||
|
if (o == IntPtr.Zero)
|
||||||
|
return null;
|
||||||
|
|
||||||
Opaque opaque = (Opaque)Activator.CreateInstance (type, new object[] { o });
|
Opaque opaque = (Opaque)Activator.CreateInstance (type, new object[] { o });
|
||||||
if (owned) {
|
if (owned) {
|
||||||
if (opaque.owned) {
|
if (opaque.owned) {
|
||||||
|
Loading…
Reference in New Issue
Block a user