Exemplo n.º 1
0
        void StartRipple(float x, float y)
        {
            if (effect?.IsDisabled ?? true)
            {
                return;
            }

            if (!effect.NativeAnimation)
            {
                return;
            }

            if (effect.CanExecute)
            {
                UpdateRipple(effect.NativeAnimationColor);
                if (rippleView != null)
                {
                    rippleView.Enabled = true;
                    rippleView.BringToFront();
                    ripple?.SetHotspot(x, y);
                    rippleView.Pressed = true;
                }
                else if (IsForegroundRippleWithTapGestureRecognizer)
                {
                    ripple?.SetHotspot(x, y);
                    View.Pressed = true;
                }
            }
            else if (rippleView == null)
            {
                UpdateRipple(XColor.Transparent);
            }
        }
Exemplo n.º 2
0
 private bool StartRipple(float x, float y)
 {
     if (_effect.NativeAnimation && _viewOverlay.Background is RippleDrawable)
     {
         _viewOverlay.BringToFront();
         _ripple.SetHotspot(x, y);
         _viewOverlay.Pressed = true;
         return(true);
     }
     return(false);
 }
Exemplo n.º 3
0
        void StartRipple(float x, float y)
        {
            if (effect?.IsDisabled ?? true)
            {
                return;
            }

            if (effect.CanExecute && effect.NativeAnimation && viewOverlay?.Background is RippleDrawable)
            {
                UpdateRipple();
                viewOverlay.BringToFront();
                ripple.SetHotspot(x, y);
                viewOverlay.Pressed = true;
            }
        }
Exemplo n.º 4
0
        void StartRipple(float x, float y)
        {
            if (effect?.IsDisabled ?? true)
            {
                return;
            }

            if (effect.CanExecute && effect.NativeAnimation && rippleView != null)
            {
                UpdateRipple();
                rippleView.Enabled = true;
                rippleView.BringToFront();
                ripple?.SetHotspot(x, y);
                rippleView.Pressed = true;
            }
        }