use of com.looklook.xinghongfei.looklook.view.GridItemDividerDecoration in project LookLook by xinghongfei.
the class TopNewsFragment method initialView.
private void initialView() {
initialListener();
mLinearLayoutManager = new WrapContentLinearLayoutManager(getContext());
recycle.setLayoutManager(mLinearLayoutManager);
recycle.setHasFixedSize(true);
recycle.addItemDecoration(new GridItemDividerDecoration(getContext(), R.dimen.divider_height, R.color.divider));
// TODO: 16/8/13 add animation
recycle.setItemAnimator(new DefaultItemAnimator());
recycle.setAdapter(mTopNewsAdapter);
recycle.addOnScrollListener(loadingMoreListener);
if (connected) {
loadDate();
}
}
use of com.looklook.xinghongfei.looklook.view.GridItemDividerDecoration in project LookLook by xinghongfei.
the class ZhihuFragment method initialView.
private void initialView() {
initialListener();
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
mLinearLayoutManager = new WrapContentLinearLayoutManager(getContext());
} else {
mLinearLayoutManager = new LinearLayoutManager(getContext());
}
recycle.setLayoutManager(mLinearLayoutManager);
recycle.setHasFixedSize(true);
recycle.addItemDecoration(new GridItemDividerDecoration(getContext(), R.dimen.divider_height, R.color.divider));
// TODO: 16/8/13 add animation
recycle.setItemAnimator(new DefaultItemAnimator());
recycle.setAdapter(zhihuAdapter);
recycle.addOnScrollListener(loadingMoreListener);
// recycle.addOnScrollListener(tooldimissListener);
if (connected) {
loadDate();
}
}
Aggregations