BigTed.ProgressHUD.CancelRingLayerAnimation C# (CSharp) Method

CancelRingLayerAnimation() public method

public CancelRingLayerAnimation ( ) : void
return void
        void CancelRingLayerAnimation()
        {
            CATransaction.Begin ();
            CATransaction.DisableActions = true;
            HudView.Layer.RemoveAllAnimations ();

            RingLayer.StrokeEnd = 0;
            if (RingLayer.SuperLayer != null) {
                RingLayer.RemoveFromSuperLayer ();
            }
            RingLayer = null;

            if (BackgroundRingLayer.SuperLayer != null) {
                BackgroundRingLayer.RemoveFromSuperLayer ();
            }
            BackgroundRingLayer = null;

            CATransaction.Commit ();
        }