protected override void Dispose(bool disposing)
        {
            if (_disposed)
            {
                return;
            }

            _disposed = true;

            if (disposing)
            {
                if (_clipPathManager != null)
                {
                    _clipPathManager.Dispose();
                    _clipPathManager = null;
                }

                if (_materialBackgroundManager != null)
                {
                    _materialBackgroundManager.Dispose();
                    _materialBackgroundManager = null;
                }

                if (_isClickListenerSet)
                {
                    SetOnClickListener(null);
                }
            }

            base.Dispose(disposing);
        }
        protected override void OnElementChanged(ElementChangedEventArgs <View> e)
        {
            base.OnElementChanged(e);

            if (e.NewElement == null)
            {
                return;
            }
            if (BackgroundManager == null)
            {
                BackgroundManager = new MaterialBackgroundManager(this);
            }

            UpdateAll();
        }