First of all, we know that the ScrollView has the Contentsize attribute, set to drag, set this property to 3 Imagevie width.
When the initialization is displayed, the direct setting of the contentsize is displayed in the position of the second ImageView, in the ScrollView proxy method, we can determine the value of the contentoffset.x, if the decrease is dragged to the left, and if it is increased, drag to the right.
If you drag to the left for 0 to finish, if twice times the width of the imgaeview represents the right drag to finish, when drag is done by default the last ImageView image of the direction of movement is set to the middle of the ImageView, Set the last ImageView image to nil, the middle of the ImageView Imgae move forward one step, the opposite direction is the same, set up, directly set ScrollView Contentoffset for the second ImageView position, After setting, you will not see a noticeable animation, which will force the scrolling view to be reset by the original parameters.
Timer function: When the picture starts to drag, the timer count variable resets to 0, when the timer count variable reaches a certain value, this time call ScrollView direction, set Contentoffset animation method to the right to slide a imageview width, The drag method in the proxy method is invoked for position and fixup parameters
The code is attached later, small dots add just a friendly hint, in fact very simple
iOS development, using Uiscrollview and timers to implement an auto-infinite scrolling banner (of course, touch-drag is also supported)