Skip to content

Commit

Permalink
添加indicator,并发布1.0.0版本
Browse files Browse the repository at this point in the history
  • Loading branch information
hanhailong committed Sep 30, 2017
1 parent 552748b commit 5064d57
Show file tree
Hide file tree
Showing 4 changed files with 51 additions and 10 deletions.
43 changes: 36 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,17 @@ allprojects {

```
dependencies {
compile 'com.github.hanhailong:GridPagerSnapHelper:0.0.3'
compile 'com.github.hanhailong:GridPagerSnapHelper:1.0.0'
}
```

## Jcenter(Recommend)

```
compile 'com.hhl:gridpagersnaphelper:0.0.3'
compile 'com.hhl:gridpagersnaphelper:1.0.0'
// Optional , config indicator
compile 'com.hhl:recyclerviewindicator:1.0.0'
```

## Maven
Expand All @@ -47,7 +50,16 @@ dependencies {
<dependency>
<groupId>com.hhl</groupId>
<artifactId>gridpagersnaphelper</artifactId>
<version>0.0.3</version>
<version>1.0.0</version>
<type>pom</type>
</dependency>
// Optional , config indicator
<dependency>
<groupId>com.hhl</groupId>
<artifactId>recyclerviewindicator</artifactId>
<version>1.0.0</version>
<type>pom</type>
</dependency>
```
Expand Down Expand Up @@ -136,6 +148,27 @@ Here,I have provided three transform order functions

You can impl your custom row funcitons by extends **AbsRowDataTransform**

**Step4. (Optional) Config Indicator**
```
CirclePageIndicator indicator = (CirclePageIndicator) findViewById(R.id.first_page_indicator);
indicator.setRecyclerView(firstRV);
//Note: pageColumn must be config
indicator.setPageColumn(column);
indicator.setOnPageChangeListener(new OnPageChangeListener() {
@Override
public void onPageSelected(int position) {
}
@Override
public void onPageScrollStateChanged(int state) {
}
});
```


# Why use AbsRowDataTransform?

In general,horizontal direction GridLayoutManager layout like this:
Expand All @@ -149,10 +182,6 @@ But,We want is the following case :
so,We need to make a transformation of the data.Here,**AbsRowDataTransform** can meet your needs.


# TODO

1. add indicator function

# Author

hanhailong worked in 58同城,A fantastic website
Expand Down
6 changes: 4 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,16 @@ dependencies {
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support:support-v4:25.3.1'

compile project(':gridpagersnaphelper')
// compile project(':gridpagersnaphelper')

compile 'com.github.bumptech.glide:glide:4.0.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.0.0'

// compile 'com.github.hanhailong:GridPagerSnapHelper:0.0.2'

// compile 'com.hhl:gridpagersnaphelper:0.0.3'
compile 'com.hhl:gridpagersnaphelper:1.0.0'

compile project(':recyclerviewindicator')

// compile 'com.hhl:recyclerviewindicator:1.0.0'
}
2 changes: 1 addition & 1 deletion gridpagersnaphelper/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ publish {
userOrg = 'hanhailong'
groupId = 'com.hhl'
artifactId = 'gridpagersnaphelper'
publishVersion = '0.0.3'
publishVersion = '1.0.0'
desc = 'A powerful tools to impl grid paging layout by RecyclerView'
website = 'https://github.com/hanhailong/GridPagerSnapHelper'
}
10 changes: 10 additions & 0 deletions recyclerviewindicator/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
apply plugin: 'com.android.library'
apply plugin: 'com.novoda.bintray-release'

android {
compileSdkVersion 25
Expand Down Expand Up @@ -31,3 +32,12 @@ dependencies {

compile 'com.android.support:recyclerview-v7:25.3.1'
}

publish {
userOrg = 'hanhailong'
groupId = 'com.hhl'
artifactId = 'recyclerviewindicator'
publishVersion = '1.0.0'
desc = 'A indicator for gridpagersnaphelper'
website = 'https://github.com/hanhailong/GridPagerSnapHelper'
}

0 comments on commit 5064d57

Please sign in to comment.