Commit Graph

8 Commits

Author SHA1 Message Date
Mikkel Kruse Johnsen
a8d9a119d8 Update to Gtk 3.18.2
Had to change gapi2xml.pl to use the new properties method/macro in gtkwindow.c
- Issue, "invisible-chars" and "inner-border" is generated twice in gtkentry.c

Made patch to gwin32registrykey to use little endian by default. So Windows om ARM may fail.
2015-11-10 11:37:34 +01:00
Andrés G. Aragoneses
8aaed84e5e cairo: Fix remaining leaks when finalizer gets called
Apply same finalizer leak fix to the rest of IDisposable-ownership
cairo classes as the one recently committed for Cairo.Context[1].

[1] https://github.com/mono/gtk-sharp/commit/41eeecbf9a6d8
2013-11-30 15:34:29 +01:00
Andrés G. Aragoneses
70d1827058 cairo: Throw ObjectDisposedException after an object has been disposed
Potentially all these IDisposable classes could be used after being
disposed, which would result in native crashes. We now do an explicit
check and throw an exception in managed land when the object has been
disposed.

This is particularly useful because:
 a/ the native crashes are quite obscure, there no indication that
you're using a disposed object
 b/ Gtk# is passing Context instances to user methods, and disposes them
when the method returns. So if the user code keeps a reference to the
Context, there a good chance it will try to use it after it's disposed.

Other changes in this patch include:
 * Renaming a parameter to be more consistent with the other subsequent
ctor called.
 * Replacing implementation of some [Obsolete()] methods with the call
to the methods they were replaced with, to avoid redundancy and the
need for more CheckDisposed() calls than necessary.
 * Throw ArgumentException when receiving an IntPtr.Zero as a handle,
as a way to protect ourselves from wrapping invalid native pointers,
and throwing ObjectDisposedExceptions because the object was invalid in
the first place.

Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
2013-11-24 15:56:26 +01:00
Michael Hutchinson
0fd72adae0 cairo: Destroy should suppress finalizer 2013-07-26 17:43:26 -05:00
Michael Hutchinson
38d1a3f13e cairo: Introduce the concept of reference ownership
Also:
  * improving naming consistency
  * obsolete old/broken stuff
  * clean up tabs/space mix

NOTE: this removes the wrapper caches for Pattern and Surface as
there was no reliable way to clear them.

This is a merge from changes in Mono.Cairo in mono 3.2.
2013-07-26 17:43:11 -05:00
Michael Hutchinson
5a78a5d177 cairo: Add mechanism to debug missing Dispose calls
Enabled by setting a new MONO_CAIRO_DEBUG_DISPOSE environment variable.
2013-07-26 10:34:45 -05:00
Michael Hutchinson
116d9fcc95 cairo: Clean up dispose implementations 2013-07-26 10:10:01 -05:00
Mike Kestner
b20d37c79c 2008-10-09 Mike Kestner <mkestner@novell.com>
* cairo/*.cs: flatten source hierarchy to simplify win32 build.
	* sample/Makefile.am: fix a ref issue with local cairo.

svn path=/trunk/gtk-sharp/; revision=115401
2008-10-09 23:53:18 +00:00