Author: jackson
Date: 2007-06-20 13:15:36 -0400 (Wed, 20 Jun 2007)
New Revision: 80337
Modified:
trunk/olive/class/agclr/System.Windows/ChangeLog
trunk/olive/class/agclr/System.Windows/UIElement.cs
Log:
* UIElement.cs: Invoke the loaded event.
Modified: trunk/olive/class/agclr/System.Windows/ChangeLog
===================================================================
--- trunk/olive/class/agclr/System.Windows/ChangeLog 2007-06-20 16:49:12 UTC
(rev 80336)
+++ trunk/olive/class/agclr/System.Windows/ChangeLog 2007-06-20 17:15:36 UTC
(rev 80337)
@@ -1,3 +1,7 @@
+2007-06-20 Jackson Harper <[EMAIL PROTECTED]>
+
+ * UIElement.cs: Invoke the loaded event.
+
2007-06-20 Rolf Bjarne Kvinge <[EMAIL PROTECTED]>
* DependencyProperty.cs: Add better exception message.
Modified: trunk/olive/class/agclr/System.Windows/UIElement.cs
===================================================================
--- trunk/olive/class/agclr/System.Windows/UIElement.cs 2007-06-20 16:49:12 UTC
(rev 80336)
+++ trunk/olive/class/agclr/System.Windows/UIElement.cs 2007-06-20 17:15:36 UTC
(rev 80337)
@@ -45,7 +45,9 @@
public static readonly DependencyProperty VisibilityProperty;
public static readonly DependencyProperty ResourcesProperty;
public static readonly DependencyProperty ZIndexProperty;
-
+
+ private UnmanagedEventHandler loaded_delegate;
+
static UIElement ()
{
OpacityProperty = DependencyProperty.Lookup
(Kind.UIELEMENT, "Opacity", typeof (double));
@@ -67,6 +69,8 @@
internal UIElement (IntPtr raw) : base (raw)
{
+ loaded_delegate = new UnmanagedEventHandler
(InvokeLoaded);
+ Events.AddHandler (raw, "Loaded", loaded_delegate);
}
public Geometry Clip {
@@ -222,7 +226,13 @@
if (h != null)
h (this, m);
}
-
+
+ private void InvokeLoaded (IntPtr data)
+ {
+ if (Loaded != null)
+ Loaded (this, EventArgs.Empty);
+ }
+
protected internal override Kind GetKind ()
{
return Kind.UIELEMENT;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches