Пример #1
0
        protected override void OnDetached()
        {
            UIView recipient = Control == null ? Container : Control;

            if (gradientSubView != null)
            {
                gradientSubView.RemoveFromSuperview();

                gradientSubView.Dispose();
                gradientSubView = null;
            }
        }
Пример #2
0
        protected override void OnAttached()
        {
            UIView recipient = Control == null ? Container : Control;

            try
            {
                gradientSubView = new GradientUIView(recipient.Bounds, (GradientEffect)Element.Effects.First(e => e is GradientEffect));

                recipient.InsertSubview(gradientSubView, 0);
            }
            catch (Exception ex)
            {
                Exception ex2 = ex;
            }
        }