Skip to content

Commit 5b477bd

Browse files
authored
Update WardRecycler.kt
intorduce enableLoadMoreProgress to use library progress or not
1 parent cc8437a commit 5b477bd

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

wrecycler/src/main/java/com/ward/wrecycler/WardRecycler.kt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ open class WardRecycler @JvmOverloads constructor(context: Context, attributeSet
3030
var enableLoadMore = true
3131

3232
var isLastPage = false
33+
34+
var enableLoadMoreProgress = true
3335

3436
var progressColor = Color.DKGRAY
3537
set(value) {
@@ -91,8 +93,8 @@ open class WardRecycler @JvmOverloads constructor(context: Context, attributeSet
9193
}
9294

9395
private fun showProgressBar() {
94-
95-
progressView.visibility = View.VISIBLE
96+
if(enableLoadMoreProgress)
97+
progressView.visibility = View.VISIBLE
9698
recyclerView.post{
9799
recyclerView.invalidateItemDecorations()
98100
}

0 commit comments

Comments
 (0)