public void SeparatorMoved(Point mouse, Point splitter)
{
// Calculation depends on use of the right to left layout setting
if (CommonHelper.GetRightToLeftLayout(this) && (RightToLeft == RightToLeft.Yes))
{
if (Orientation == Orientation.Vertical)
SplitterDistance = Width - splitter.X;
else
SplitterDistance = Height - splitter.Y;
}
else
{
if (Orientation == Orientation.Vertical)
SplitterDistance = splitter.X;
else
SplitterDistance = splitter.Y;
}
// Fire the event that indicates the splitter has finished being moved
SplitterEventArgs e = new SplitterEventArgs(mouse.X, mouse.Y, splitter.X, splitter.Y);
OnSplitterMoved(e);
}