Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/CSnowStack/LikeELMLeftLoad
仿饿了么左滑跳转
https://github.com/CSnowStack/LikeELMLeftLoad
Last synced: 2 months ago
JSON representation
仿饿了么左滑跳转
- Host: GitHub
- URL: https://github.com/CSnowStack/LikeELMLeftLoad
- Owner: CSnowStack
- Created: 2016-12-27T00:55:13.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2016-12-29T05:15:34.000Z (about 8 years ago)
- Last Synced: 2024-08-02T01:18:51.302Z (6 months ago)
- Language: Java
- Size: 1.88 MB
- Stars: 44
- Watchers: 4
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-github-android-ui - LikeELMLeftLoad - 仿饿了么左滑跳转 (布局)
README
## LikeELMLeftLoad
仿饿了么左滑跳转![预览](https://github.com/CSnowStack/LikeELMLeftLoad/blob/master/img/preview.gif)
## 膜拜巴神
## 使用
### 加依赖
```java
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:25.1.0'
compile 'com.android.support:design:25.1.0'
}```
### 把View文件内的文件放到你们那的项目中,还有一些配置文件也要拉过去
### 代码使用
```java
mRecyclerView= (RecyclerView) findViewById(R.id.rcv);
mRecyclerView.setLayoutManager(new LinearLayoutManager(this,LinearLayoutManager.HORIZONTAL,false));
mRecyclerView.setAdapter(new ELMAdapter());mPullLeftLoadMoreLayout= (PullLeftLoadMoreLayout) findViewById(R.id.pull_load_layout);
mPullLeftLoadMoreLayout.addView(getResources().getDimensionPixelOffset(R.dimen.item_img));
mPullLeftLoadMoreLayout.setFillLoadingColor(ContextCompat.getColor(this,R.color.colorAccent));
mPullLeftLoadMoreLayout.setOnGoListener(new LoadingView.OnNoticeGoListener() {
@Override
public void go() {
Toast.makeText(MainActivity.this,"跳转页面",Toast.LENGTH_SHORT).show();
}
});```