一个仿 即刻APP 滑动返回效果的小东西
Switch branches/tags
Nothing to show
Clone or download
Latest commit 2439b88 Sep 13, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app 将slideback拆成独立的moudule Sep 12, 2018
chentianslideback 更换了实现方式,发布到了jitpack Sep 12, 2018
gradle/wrapper first commit Aug 19, 2018
.gitignore first commit Aug 19, 2018
LICENSE Initial commit Aug 19, 2018
README.md Update README.md Sep 13, 2018
build.gradle 配置jitpack Sep 12, 2018
gradle.properties first commit Aug 19, 2018
gradlew first commit Aug 19, 2018
gradlew.bat first commit Aug 19, 2018
settings.gradle 将slideback拆成独立的moudule Sep 12, 2018

README.md

SlideBack

一个仿 即刻APP 滑动返回效果的小东西

效果

https://user-gold-cdn.xitu.io/2018/8/20/1655691cada3b454?imageslim

使用方法:

Step 1. 在你项目的根build.gradle中添加jitpack.io库

allprojects {
	repositories {
		...
		maven { url 'https://jitpack.io' }
	}
}

Step 2. 添加SlideBack的依赖

dependencies {
	implementation 'com.github.ChenTianSaber:SlideBack:v0.6.0'
}

Step 3. 将项目中继承的Activity换成SlideBackActivity

public class YourActivity extends SlideBackActivity

Step 4. 重写slideBackSuccess(当滑动有效时会回调这个方法,可以在这里进行回退操作或其他)

@Override
protected void slideBackSuccess() {
   finish();//或者其他
}
希望大家能给我Star...