Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/libq/ScrollTrackView
Browse files Browse the repository at this point in the history
  • Loading branch information
libq committed Apr 10, 2018
2 parents 56650df + 967bdd5 commit 4511d06
Showing 1 changed file with 30 additions and 2 deletions.
32 changes: 30 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
}
## module 下的 build.gradle :
dependencies {
compile 'com.github.libq:ScrollTrackView:1.0.1'
compile 'com.github.libq:ScrollTrackView:1.0.2'
}

## xml:
Expand All @@ -30,8 +30,36 @@
app:space_size="5dp"
app:track_item_width="1dp"
app:track_fragment_count="10"
app:auto_run="true"
app:loop_run="false"
app:cut_duration="10000"
app:auto_run="false"
/>
```
## java:
```
float[] template = {0.9f,0.6f,0.7f,0.5f,0.8f,0.4f,0.5f,0.2f,0.6f,0.8f,0.8f};
stv.setTrackTemplateData(template);
stv.setDuration(20000); // 音频时间
stv.setCutDuration(10000);//屏幕左边跑到右边持续的时间
stv.setTrackFragmentCount(10);//1 中是一个片段,这个参数表示重复1中片段画10次
stv.setLoopRun(false);//设置是否循环跑进度
stv.setOnProgressRunListener(new ScrollTrackView.OnProgressRunListener() {
@Override
public void onTrackStart(int ms) {
}
@Override
public void onTrackStartTimeChange(int ms) {
}
@Override
public void onTrackEnd() {
}
});
```


0 comments on commit 4511d06

Please sign in to comment.