baoyongzhang / android-PullRefreshLayout

This component like SwipeRefreshLayout, it is more beautiful than SwipeRefreshLayout.
MIT License
2.07k stars 517 forks source link

setRefreshing programmatically not working properly #5

Closed tejada closed 9 years ago

tejada commented 9 years ago

Hi, I think you should add this couple of lines to your code as if you try to call setRefreshing(true) programmatically the drawable animation won't show.

public void setRefreshing(boolean refreshing) { if (refreshing) mRefreshDrawable.setPercent(1f); if (mRefreshing != refreshing) { setRefreshing(refreshing, false /* notify */); } }

Regards and thanks for your contribution. Danny

baoyongzhang commented 9 years ago

Nice!!!