Open shahimclt opened 7 years ago
set rippleAlpha
to 0
I am also having this problem, and setting the alpha to 0
did not help.
Worked around this problem by using my own boolean flag to prevent multiple firings.
if (inFlight)
return
inFlight = true
//some code...
inFlight = false
@shahimclt
you have to customise the library>>
Write below public method in MaterialRippleLayout class
public void setEnableRipple(boolean enable) { this.rippleEnable = enable;//Default Value Should be set to 'true' at class level }
And in onTouch:
@Override public boolean onTouchEvent(MotionEvent event) { boolean superOnTouchEvent = super.onTouchEvent(event); if (!rippleEnable) return superOnTouchEvent; ..... ..... }
Usage :
materialRippleLayout.setEnableRipple(false);
That's it..
Works for me .
rippleLayout.setRippleOverlay(false);
rippleLayout.setDefaultRippleAlpha(0);
set
rippleAlpha
to 0
then set it's value to 51 in clickListener
I Applied MRL on a LinearLayout. I want to disable/enable clicks on that view using
view.setClickable(boolean)
. but the MRL seems to ignore that. So is there any way to enable/disable the ripple and click action?