Search in sources :

Example 1 with ProfileAdapter

use of com.yalantis.starwarsdemo.adapter.ProfileAdapter in project StarWars.Android by Yalantis.

the class SideFragment method onViewCreated.

@Override
public void onViewCreated(View view, Bundle savedInstanceState) {
    super.onViewCreated(view, savedInstanceState);
    mTilesFrameLayout.setOnAnimationFinishedListener(this);
    mRecycler.setLayoutManager(new LinearLayoutManager(getContext()));
    mRecycler.setAdapter(new ProfileAdapter(getContext(), getUser(), this));
    setUpToolbar(mToolbar);
    mHeader.setImageResource(getUser().getPhotoRes());
    if (getArguments() != null) {
        mAppBarLayout.setExpanded(getArguments().getBoolean(ARG_SHOULD_EXPAND), false);
    }
}
Also used : ProfileAdapter(com.yalantis.starwarsdemo.adapter.ProfileAdapter) LinearLayoutManager(android.support.v7.widget.LinearLayoutManager)

Aggregations

LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)1 ProfileAdapter (com.yalantis.starwarsdemo.adapter.ProfileAdapter)1