2008-05-28 Lluis Sanchez Gual <lluis@novell.com>

* gtk/Object.custom: If all destroy handlers have been
	unregistered, remove the hashtable entry since it is
	not needed anymore.


svn path=/trunk/gtk-sharp/; revision=104287
This commit is contained in:
Lluis Sanchez 2008-05-28 16:34:50 +00:00
parent 64ff72c07f
commit d6be561887
2 changed files with 11 additions and 1 deletions

View file

@ -1,3 +1,9 @@
2008-05-28 Lluis Sanchez Gual <lluis@novell.com>
* gtk/Object.custom: If all destroy handlers have been
unregistered, remove the hashtable entry since it is
not needed anymore.
2008-05-27 Mike Kestner <mkestner@novell.com>
* generator/Method.cs (GenerateBody): when generating value type

View file

@ -57,7 +57,11 @@
}
remove {
EventHandler handler = (EventHandler) DestroyHandlers [Handle];
DestroyHandlers [Handle] = Delegate.Remove (handler, value);
handler = (EventHandler) Delegate.Remove (handler, value);
if (handler != null)
DestroyHandlers [Handle] = handler;
else
DestroyHandlers.Remove (Handle);
}
}