Skip to content

Instantly share code, notes, and snippets.

View dinorahtovar's full-sized avatar

Dinorah Tovar dinorahtovar

View GitHub Profile
@dinorahtovar
dinorahtovar / ViewPager without drag event
Last active December 20, 2017 18:34
Custome ViewPager without Scroller (disable paging)
/**
* Created by Dinorah Tovar on 12/20/17.
* ViewPager
*/
public class CustomViewPager extends ViewPager {
public CustomViewPager(Context context) {
super(context);
setMyScroller();
@dinorahtovar
dinorahtovar / RecyclerView, RecyclerViewAdapter y RecyclerViewHolder
Last active December 20, 2017 18:32
RecyclerView implementation with different holders and different files
/**
* Created by Dinorah Tovar on 12/20/17.
* RecyclerView Implementation inside Activity/Fragment
*/
//...
RecyclerViewAdapter adapter = new RecyclerViewAdapter();
final LinearLayoutManager layoutManager = new LinearLayoutManager(getActivity());
layoutManager.setOrientation(LinearLayoutManager.VERTICAL);
recyclerView.setLayoutManager(layoutManager);