diff --git a/build.gradle b/build.gradle index 93b210e..e3f67ba 100755 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ buildscript { jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:1.0.0' + classpath 'com.android.tools.build:gradle:2.2.2' } } diff --git a/gradle.properties b/gradle.properties index eea214d..9ea8730 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ ANDROID_BUILD_MIN_SDK_VERSION=8 ANDROID_BUILD_TARGET_SDK_VERSION=22 -ANDROID_BUILD_SDK_VERSION=22 -ANDROID_BUILD_TOOLS_VERSION=22.0.1 +ANDROID_BUILD_SDK_VERSION=25 +ANDROID_BUILD_TOOLS_VERSION=25 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 76dedcb..16b42c5 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip diff --git a/ptr-demo/src/in/srain/cube/views/ptr/demo/app/PtrDemoApplication.java b/ptr-demo/src/in/srain/cube/views/ptr/demo/app/PtrDemoApplication.java index ca13220..3334664 100644 --- a/ptr-demo/src/in/srain/cube/views/ptr/demo/app/PtrDemoApplication.java +++ b/ptr-demo/src/in/srain/cube/views/ptr/demo/app/PtrDemoApplication.java @@ -32,7 +32,6 @@ public void onCreate() { CubeDebug.DEBUG_IMAGE = true; PtrFrameLayout.DEBUG = true; - PtrFrameLayout.DEBUG = false; ImageLoaderFactory.setDefaultImageReSizer(DemoDuiTangImageReSizer.getInstance()); ImageLoaderFactory.setDefaultImageLoadHandler(new PtrImageLoadHandler()); diff --git a/ptr-lib/src/in/srain/cube/views/ptr/PtrFrameLayout.java b/ptr-lib/src/in/srain/cube/views/ptr/PtrFrameLayout.java index dc1ea65..031b60a 100755 --- a/ptr-lib/src/in/srain/cube/views/ptr/PtrFrameLayout.java +++ b/ptr-lib/src/in/srain/cube/views/ptr/PtrFrameLayout.java @@ -370,7 +370,9 @@ private void movePos(float deltaY) { } mPtrIndicator.setCurrentPos(to); + int change = to - mPtrIndicator.getLastPosY(); + updatePos(change); }