use of com.liskovsoft.smartyoutubetv2.tv.presenter.CustomListRowPresenter in project SmartTubeNext by yuliskov.
the class PlaybackFragment method initPresenters.
private void initPresenters() {
mRowPresenter = new CustomListRowPresenter() {
@Override
protected void onBindRowViewHolder(RowPresenter.ViewHolder holder, Object item) {
super.onBindRowViewHolder(holder, item);
// Set position of item inside first row (playlist items)
if (mRowsSupportFragment != null && mRowsSupportFragment.getVerticalGridView().getSelectedPosition() == 0) {
int index = getSuggestedItemIndex();
if (index > 0) {
ViewHolder vh = (ViewHolder) holder;
vh.getGridView().setSelectedPosition(index);
}
}
}
@Override
protected void onRowViewSelected(RowPresenter.ViewHolder holder, boolean selected) {
super.onRowViewSelected(holder, selected);
updatePlayerBackground();
}
};
mCardPresenter = new VideoCardPresenter();
}
use of com.liskovsoft.smartyoutubetv2.tv.presenter.CustomListRowPresenter in project SmartTubeNext by yuliskov.
the class SearchTagsFragmentBase method onCreate.
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
mProgressBarManager = new ProgressBarManager();
mResultsPresenter = new CustomListRowPresenter();
mResultsAdapter = new ArrayObjectAdapter(mResultsPresenter);
mSearchTagsAdapter = new TagAdapter(getActivity(), "");
setSearchResultProvider(this);
setupListeners();
}
use of com.liskovsoft.smartyoutubetv2.tv.presenter.CustomListRowPresenter in project SmartTubeNext by yuliskov.
the class MultipleRowsFragment method setupAdapter.
private void setupAdapter() {
if (mVideoGroupAdapters == null) {
mVideoGroupAdapters = new HashMap<>();
}
if (mRowsAdapter == null) {
mRowPresenter = new CustomListRowPresenter();
mRowsAdapter = new ArrayObjectAdapter(mRowPresenter);
setAdapter(mRowsAdapter);
}
}
Aggregations