Dashboard/Quik/Controls/HierarchyEvents.cs

38 lines
883 B
C#
Raw Normal View History

using System;
namespace Quik.Controls
{
public class ParentChangedEventArgs : EventArgs
{
public Control NewParent { get; }
public ParentChangedEventArgs(Control newParent)
{
NewParent = newParent;
}
public static ParentChangedEventArgs Disowned { get; } = new ParentChangedEventArgs(null);
}
public class RootChangedEventArgs : EventArgs
{
public RootControl NewRoot { get; }
public RootChangedEventArgs(RootControl newRoot)
{
NewRoot = newRoot;
}
public static RootChangedEventArgs Disowned { get; } = new RootChangedEventArgs(null);
}
public class FocusChangedEventArgs : EventArgs
{
public Control Focused { get; }
public FocusChangedEventArgs(Control focused)
{
Focused = focused;
}
}
}