BouncingBallAccelerate.MainWindow.CompositionTargetOnRendering C# (CSharp) Method

CompositionTargetOnRendering() private method

private CompositionTargetOnRendering ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void
        private void CompositionTargetOnRendering(object sender, EventArgs e)
        {
            var time = DateTime.Now - startTime;
            var location = scene.GetBallLocation(time);

            MainBall.SetValue(Canvas.LeftProperty, location.X);
            MainBall.SetValue(Canvas.TopProperty, location.Y);
        }
    }