Method for dragging elastic interface of touch screen

2014 
The invention relates to a touch screen, in particular to a method for a touch screen to realize an elastic interface, and aims at providing a method for dragging the elastic interface. The method comprises the following steps of setting the value of a proportional coefficient C between the window moving distance and the finger sliding distance; if a child window needs to roll and display in a parent window, enabling an user to downwards slide the interface and monitor the touch event of the child interface when the top most end of the child window is visible, and recording the coordinate StartPoint (x, y) when the user presses down fingers; when the fingers slide, recording the sliding position EndPoint (x, y) of the fingers on the interface, namely deltaX=EndPoint.x - StartPoint.x, and delta Y=EndPoint.y - StartPoint.y; if deltaY/deltaX is smaller than or equal to 1, not operating; or else, calculating the window moving distance MoveY = deltaY*C, then drawing the child window, and moving the distance start point by MoveY; when the user releases the fingers, firstly moving three MoveY to a window start position, then updating the MoveY as the distance from the current window position to the start position, then moving three MoveY to the start position, and repeating the step until the child window is moved to the start position. The method is suitable for the touch screen.
    • Correction
    • Source
    • Cite
    • Save
    • Machine Reading By IdeaReader
    0
    References
    0
    Citations
    NaN
    KQI
    []