Search in sources :

Example 1 with InstructionListAdapter

use of com.mapbox.services.android.navigation.ui.v5.summary.list.InstructionListAdapter in project mapbox-navigation-android by mapbox.

the class InstructionView method initDirectionsRecyclerView.

/**
 * Sets up the {@link RecyclerView} that is used to display the list of instructions.
 */
private void initDirectionsRecyclerView() {
    instructionListAdapter = new InstructionListAdapter();
    rvInstructions.setAdapter(instructionListAdapter);
    rvInstructions.setHasFixedSize(true);
    rvInstructions.setItemAnimator(new DefaultItemAnimator());
    rvInstructions.setLayoutManager(new LinearLayoutManager(getContext()));
}
Also used : LinearLayoutManager(android.support.v7.widget.LinearLayoutManager) InstructionListAdapter(com.mapbox.services.android.navigation.ui.v5.summary.list.InstructionListAdapter) DefaultItemAnimator(android.support.v7.widget.DefaultItemAnimator)

Aggregations

DefaultItemAnimator (android.support.v7.widget.DefaultItemAnimator)1 LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)1 InstructionListAdapter (com.mapbox.services.android.navigation.ui.v5.summary.list.InstructionListAdapter)1