Search in sources :

Example 1 with AvengersListAdapter

use of saulmm.avengers.views.adapter.AvengersListAdapter in project Avengers by saulmm.

the class CharacterListActivity method bindCharacterList.

@Override
public void bindCharacterList(List<MarvelCharacter> avengers) {
    mCharacterListAdapter = new AvengersListAdapter(avengers, this, (position, sharedView, characterImageView) -> {
        mAvengersListPresenter.onElementClick(position);
    });
    mAvengersRecycler.setAdapter(mCharacterListAdapter);
}
Also used : AvengersListAdapter(saulmm.avengers.views.adapter.AvengersListAdapter) Bundle(android.os.Bundle) MarvelCharacter(saulmm.avengers.entities.MarvelCharacter) ProgressBar(android.widget.ProgressBar) ButterKnife(butterknife.ButterKnife) Utils(saulmm.avengers.utils.Utils) OnScrollListener(android.support.v7.widget.RecyclerView.OnScrollListener) OnClick(butterknife.OnClick) Inject(javax.inject.Inject) ActivityOptions(android.app.ActivityOptions) View(android.view.View) Bind(butterknife.Bind) CharacterListView(saulmm.avengers.mvp.views.CharacterListView) CollapsingToolbarLayout(android.support.design.widget.CollapsingToolbarLayout) ActivityModule(saulmm.avengers.injector.modules.ActivityModule) AvengersApplication(saulmm.avengers.AvengersApplication) LinearLayoutManager(android.support.v7.widget.LinearLayoutManager) AppCompatActivity(android.support.v7.app.AppCompatActivity) DaggerAvengersComponent(saulmm.avengers.injector.components.DaggerAvengersComponent) RecyclerView(android.support.v7.widget.RecyclerView) List(java.util.List) TextView(android.widget.TextView) Toolbar(android.support.v7.widget.Toolbar) R(saulmm.avengers.R) RecyclerInsetsDecoration(saulmm.avengers.views.views.RecyclerInsetsDecoration) CharacterListPresenter(saulmm.avengers.mvp.presenters.CharacterListPresenter) Snackbar(android.support.design.widget.Snackbar) AvengersListAdapter(saulmm.avengers.views.adapter.AvengersListAdapter)

Aggregations

ActivityOptions (android.app.ActivityOptions)1 Bundle (android.os.Bundle)1 CollapsingToolbarLayout (android.support.design.widget.CollapsingToolbarLayout)1 Snackbar (android.support.design.widget.Snackbar)1 AppCompatActivity (android.support.v7.app.AppCompatActivity)1 LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)1 RecyclerView (android.support.v7.widget.RecyclerView)1 OnScrollListener (android.support.v7.widget.RecyclerView.OnScrollListener)1 Toolbar (android.support.v7.widget.Toolbar)1 View (android.view.View)1 ProgressBar (android.widget.ProgressBar)1 TextView (android.widget.TextView)1 Bind (butterknife.Bind)1 ButterKnife (butterknife.ButterKnife)1 OnClick (butterknife.OnClick)1 List (java.util.List)1 Inject (javax.inject.Inject)1 AvengersApplication (saulmm.avengers.AvengersApplication)1 R (saulmm.avengers.R)1 MarvelCharacter (saulmm.avengers.entities.MarvelCharacter)1