소스 검색

Pull&Refresh fix

Removed bounce on iOS devices and now works correctly on Android devices
ina 13 년 전
부모
커밋
b7706b7c9c
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      src/element/Lungo.Element.Pull.coffee

+ 1 - 0
src/element/Lungo.Element.Pull.coffee

@@ -96,6 +96,7 @@ Lungo.Element.Pull = (element_selector, config_data) ->
         INI_Y = (if $$.isMobile() then event.touches[0].pageY else event.pageY)
     ).bind("touchmove", (event) ->
       if not REFRESHING and STARTED
+        do event.preventDefault
         current_y = (if $$.isMobile() then event.touches[0].pageY else event.pageY)
         CURRENT_DISTANCE = current_y - INI_Y
         if CURRENT_DISTANCE >= 0