本文整理匯總了Java中com.justwayward.reader.view.SupportDividerItemDecoration類的典型用法代碼示例。如果您正苦於以下問題:Java SupportDividerItemDecoration類的具體用法?Java SupportDividerItemDecoration怎麽用?Java SupportDividerItemDecoration使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
SupportDividerItemDecoration類屬於com.justwayward.reader.view包,在下文中一共展示了SupportDividerItemDecoration類的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: configViews
import com.justwayward.reader.view.SupportDividerItemDecoration; //導入依賴的package包/類
@Override
public void configViews() {
mIndicator.setTabItemTitles(mDatas);
mViewPager.setAdapter(mAdapter);
mIndicator.setViewPager(mViewPager, 0);
rvTags.setHasFixedSize(true);
rvTags.setLayoutManager(new LinearLayoutManager(this));
rvTags.addItemDecoration(new SupportDividerItemDecoration(this, LinearLayoutManager.VERTICAL));
mTagAdapter = new SubjectTagsAdapter(this, mTagList);
mTagAdapter.setItemClickListener(this);
rvTags.setAdapter(mTagAdapter);
mPresenter.attachView(this);
mPresenter.getBookListTags();
}
示例2: configViews
import com.justwayward.reader.view.SupportDividerItemDecoration; //導入依賴的package包/類
@Override
public void configViews() {
mRecyclerView.setHasFixedSize(true);
mRecyclerView.setLayoutManager(new LinearLayoutManager(getActivity()));
mRecyclerView.addItemDecoration(new SupportDividerItemDecoration(mContext, LinearLayoutManager.VERTICAL, true));
mAdapter = new FindAdapter(mContext, mList, this);
mRecyclerView.setAdapter(mAdapter);
}
示例3: showBestComments
import com.justwayward.reader.view.SupportDividerItemDecoration; //導入依賴的package包/類
@Override
public void showBestComments(CommentList list) {
if (list.comments.isEmpty()) {
gone(headerViewHolder.tvBestComments, headerViewHolder.rvBestComments);
} else {
mBestCommentList.addAll(list.comments);
headerViewHolder.rvBestComments.setHasFixedSize(true);
headerViewHolder.rvBestComments.setLayoutManager(new LinearLayoutManager(this));
headerViewHolder.rvBestComments.addItemDecoration(new SupportDividerItemDecoration(mContext, LinearLayoutManager.VERTICAL, true));
mBestCommentListAdapter = new BestCommentListAdapter(mContext, mBestCommentList);
mBestCommentListAdapter.setOnItemClickListener(this);
headerViewHolder.rvBestComments.setAdapter(mBestCommentListAdapter);
visible(headerViewHolder.tvBestComments, headerViewHolder.rvBestComments);
}
}
示例4: configViews
import com.justwayward.reader.view.SupportDividerItemDecoration; //導入依賴的package包/類
@Override
public void configViews() {
refreshLayout.setOnRefreshListener(new RefreshListener());
mRecyclerView.setHasFixedSize(true);
linearLayoutManager = new LinearLayoutManager(this);
mRecyclerView.setLayoutManager(linearLayoutManager);
mRecyclerView.addItemDecoration(new SupportDividerItemDecoration(mContext, LinearLayoutManager.VERTICAL));
mAdapter = new BooksByTagAdapter(mContext, mList, this);
mRecyclerView.setAdapter(mAdapter);
mRecyclerView.addOnScrollListener(new RefreshListener());
mPresenter.attachView(this);
mPresenter.getBooksByTag(tag, current + "", (current + 10) + "");
}
示例5: showBestComments
import com.justwayward.reader.view.SupportDividerItemDecoration; //導入依賴的package包/類
@Override
public void showBestComments(CommentList list) {
if(list.comments.isEmpty()){
gone(headerViewHolder.tvBestComments, headerViewHolder.rvBestComments);
}else{
mBestCommentList.addAll(list.comments);
headerViewHolder.rvBestComments.setHasFixedSize(true);
headerViewHolder.rvBestComments.setLayoutManager(new LinearLayoutManager(this));
headerViewHolder.rvBestComments.addItemDecoration(new SupportDividerItemDecoration(mContext, LinearLayoutManager.VERTICAL, true));
mBestCommentListAdapter = new BestCommentListAdapter(mContext, mBestCommentList);
mBestCommentListAdapter.setOnItemClickListener(this);
headerViewHolder.rvBestComments.setAdapter(mBestCommentListAdapter);
visible(headerViewHolder.tvBestComments, headerViewHolder.rvBestComments);
}
}