use of com.eros.framework.extend.hook.ui.view.refresh.bmrefresh.BMLoadingRefresh in project WeexErosFramework by bmfe.
the class HookWxScroller method setBMRefresh.
@WXComponentProp(name = HookConstants.NAME.SHOW_REFRESH)
public void setBMRefresh(String showRefresh) {
boolean customerRefresh = WXUtils.getBoolean(showRefresh, false);
if (customerRefresh && mBMRefresh == null) {
mBMRefresh = new BMLoadingRefresh(getContext(), this);
((HookBounceScrollerView) this.getHostView()).setOnRefreshListener(mBMRefresh);
Runnable runnable = WXThread.secure(new Runnable() {
public void run() {
((HookBounceScrollerView) getHostView()).setCustomHeaderView(mBMRefresh);
}
});
this.handler.postDelayed(runnable, 100L);
}
}
use of com.eros.framework.extend.hook.ui.view.refresh.bmrefresh.BMLoadingRefresh in project WeexErosFramework by bmfe.
the class HookListComponent method addCustomRefresh.
public void addCustomRefresh() {
if (!mAddCustomRefresh || mBMRefresh != null)
return;
mBMRefresh = new BMLoadingRefresh(getContext(), this);
getHostView().setOnRefreshListener(mBMRefresh);
getHostView().postDelayed(new Runnable() {
@Override
public void run() {
if (getHostView() instanceof HookBounceRecyclerView) {
((HookBounceRecyclerView) getHostView()).setCustomHeaderView(mBMRefresh);
}
}
}, 100);
}
Aggregations