diff --git a/ActionButton.js b/ActionButton.js index ec1b9e3..5981ea8 100644 --- a/ActionButton.js +++ b/ActionButton.js @@ -35,13 +35,13 @@ const ActionButton = props => { useEffect(() => { if (props.active) { - Animated.spring(anim.current, { toValue: 1 }).start(); + Animated.spring(anim.current, { toValue: 1,useNativeDriver:false }).start(); setActive(true); setResetToken(props.resetToken); } else { props.onReset && props.onReset(); - Animated.spring(anim.current, { toValue: 0 }).start(); + Animated.spring(anim.current, { toValue: 0,useNativeDriver:false }).start(); timeout.current = setTimeout(() => { setActive(false); setResetToken(props.resetToken); @@ -148,8 +148,8 @@ const ActionButton = props => { onPressIn={props.onPressIn} onPressOut={props.onPressOut} > - - + + {_renderButtonIcon()} @@ -178,6 +178,7 @@ const ActionButton = props => { return ( { if (active) return reset(animate); if (animate) { - Animated.spring(anim.current, { toValue: 1 }).start(); + Animated.spring(anim.current, { toValue: 1,useNativeDriver:false }).start(); } else { anim.current.setValue(1); } @@ -266,7 +267,7 @@ const ActionButton = props => { if (props.onReset) props.onReset(); if (animate) { - Animated.spring(anim.current, { toValue: 0 }).start(); + Animated.spring(anim.current, { toValue: 0,useNativeDriver:false }).start(); } else { anim.current.setValue(0); } @@ -281,6 +282,7 @@ const ActionButton = props => { return (