Add a delegate method to customize the animation effect