ScrollViewDelegateProtocol can be implemented when adding a scroll view to your screen. ScrollViewDelegateProtocol includes seven optional functions.

  • scrollViewDidEndDecelerating: Invoked when the scroll view has ends decelerating the scrolling movement.
  • scrollViewDidEndDragging:willDecelerate: Invoked when dragging ends in the scroll view.
  • scrollViewDidScroll: Invoked when the user scrolls the content view within the receiver.
  • scrollViewDidScrollToTop: Invoked when the scroll view scrolls to the top of the content.
  • scrollViewShouldScrollToTop: Returns if the scroll view should scroll to the top of the content.
  • scrollViewWillBeginDecelerating: Invoked when the scroll view is starting to decelerate the scrolling movement.
  • scrollViewWillBeginDragging: Invoked when the scroll view is about to start scrolling the content.
Did this answer your question?