From 2cb7bc8356aa45050d42b7848adfeadf19209d22 Mon Sep 17 00:00:00 2001 From: Steven Kirk Date: Fri, 6 Nov 2015 19:58:00 +0100 Subject: [PATCH] Added attached/detached events to IVisual. --- src/Perspex.SceneGraph/IVisual.cs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/Perspex.SceneGraph/IVisual.cs b/src/Perspex.SceneGraph/IVisual.cs index 0491d63fad..3acb3ac27c 100644 --- a/src/Perspex.SceneGraph/IVisual.cs +++ b/src/Perspex.SceneGraph/IVisual.cs @@ -1,6 +1,7 @@ // Copyright (c) The Perspex Project. All rights reserved. // Licensed under the MIT license. See licence.md file in the project root for full license information. +using System; using Perspex.Collections; using Perspex.Media; using Perspex.VisualTree; @@ -20,6 +21,16 @@ namespace Perspex /// public interface IVisual { + /// + /// Raised when the control is attached to a rooted visual tree. + /// + event EventHandler AttachedToVisualTree; + + /// + /// Raised when the control is detached from a rooted visual tree. + /// + event EventHandler DetachedFromVisualTree; + /// /// Gets the bounds of the scene graph node relative to its parent. ///