Interface UIScrollViewDelegate

    • Method Detail

      • scrollViewDidEndDecelerating

        default void scrollViewDidEndDecelerating​(@NotNull
                                                  @NotNull UIScrollView scrollView)
        called when scroll view grinds to a halt
      • scrollViewDidEndDraggingWillDecelerate

        default void scrollViewDidEndDraggingWillDecelerate​(@NotNull
                                                            @NotNull UIScrollView scrollView,
                                                            boolean decelerate)
        called on finger up if the user dragged. decelerate is true if it will continue moving afterwards
      • scrollViewDidEndScrollingAnimation

        default void scrollViewDidEndScrollingAnimation​(@NotNull
                                                        @NotNull UIScrollView scrollView)
        called when setContentOffset/scrollRectVisible:animated: finishes. not called if not animating
      • scrollViewDidEndZoomingWithViewAtScale

        default void scrollViewDidEndZoomingWithViewAtScale​(@NotNull
                                                            @NotNull UIScrollView scrollView,
                                                            @Nullable
                                                            @Nullable UIView view,
                                                            double scale)
        scale between minimum and maximum. called after any 'bounce' animations
      • scrollViewDidScroll

        default void scrollViewDidScroll​(@NotNull
                                         @NotNull UIScrollView scrollView)
        any offset changes
      • scrollViewDidScrollToTop

        default void scrollViewDidScrollToTop​(@NotNull
                                              @NotNull UIScrollView scrollView)
        called when scrolling animation finished. may be called immediately if already at top
      • scrollViewDidZoom

        default void scrollViewDidZoom​(@NotNull
                                       @NotNull UIScrollView scrollView)
        any zoom scale changes API-Since: 3.2
      • scrollViewShouldScrollToTop

        default boolean scrollViewShouldScrollToTop​(@NotNull
                                                    @NotNull UIScrollView scrollView)
        return a yes if you want to scroll to the top. if not defined, assumes YES
      • scrollViewWillBeginDecelerating

        default void scrollViewWillBeginDecelerating​(@NotNull
                                                     @NotNull UIScrollView scrollView)
        called on finger up as we are moving
      • scrollViewWillBeginDragging

        default void scrollViewWillBeginDragging​(@NotNull
                                                 @NotNull UIScrollView scrollView)
        called on start of dragging (may require some time and or distance to move)
      • scrollViewWillBeginZoomingWithView

        default void scrollViewWillBeginZoomingWithView​(@NotNull
                                                        @NotNull UIScrollView scrollView,
                                                        @Nullable
                                                        @Nullable UIView view)
        called before the scroll view begins zooming its content API-Since: 3.2
      • scrollViewWillEndDraggingWithVelocityTargetContentOffset

        default void scrollViewWillEndDraggingWithVelocityTargetContentOffset​(@NotNull
                                                                              @NotNull UIScrollView scrollView,
                                                                              CGPoint velocity,
                                                                              @NotNull
                                                                              @NotNull CGPoint targetContentOffset)
        called on finger up if the user dragged. velocity is in points/millisecond. targetContentOffset may be changed to adjust where the scroll view comes to rest API-Since: 5.0
      • viewForZoomingInScrollView

        @Nullable
        default @Nullable UIView viewForZoomingInScrollView​(@NotNull
                                                            @NotNull UIScrollView scrollView)
        return a view that will be scaled. if delegate returns nil, nothing happens
      • scrollViewDidChangeAdjustedContentInset

        default void scrollViewDidChangeAdjustedContentInset​(@NotNull
                                                             @NotNull UIScrollView scrollView)
        Also see -[UIScrollView adjustedContentInsetDidChange] API-Since: 11.0