public void SlideOff(HorizontalEdge direction, Action onComplete)
{
// Ensure the panel is on stage.
CenterStage();
// Configure the animation.
Dictionary properties = new Dictionary();
properties[Css.Left] = direction == HorizontalEdge.Left ? 0 - Width : Width;
// Perform animation.
Container.Animate(
properties,
parentList.Slide.ToMsecs(),
parentList.Slide.Easing,
delegate
{
// On complete.
Hide();
Helper.Invoke(onComplete);
});
}