use of com.google.firebase.testing.fireperf.SlowListAdapter in project firebase-android-sdk by firebase.
the class HomeFragment method onCreateView.
public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
homeViewModel = new ViewModelProvider(this, new ViewModelProvider.NewInstanceFactory()).get(HomeViewModel.class);
View root = inflater.inflate(R.layout.fragment_home, container, false);
TextView textView = root.findViewById(R.id.text_home);
homeViewModel.getText().observe(getViewLifecycleOwner(), textView::setText);
RecyclerView numbersList = root.findViewById(R.id.rv_numbers_home);
numbersList.setLayoutManager(new LinearLayoutManager(requireContext()));
numbersList.setHasFixedSize(true);
numbersList.setAdapter(new SlowListAdapter(NUM_LIST_ITEMS));
return root;
}
use of com.google.firebase.testing.fireperf.SlowListAdapter in project firebase-android-sdk by firebase.
the class SlowFragment method onCreateView.
public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
slowViewModel = new ViewModelProvider(this, new ViewModelProvider.NewInstanceFactory()).get(SlowViewModel.class);
View root = inflater.inflate(R.layout.fragment_slow, container, false);
TextView textView = root.findViewById(R.id.text_slow);
slowViewModel.getText().observe(getViewLifecycleOwner(), textView::setText);
RecyclerView numbersList = root.findViewById(R.id.rv_numbers_slow);
numbersList.setLayoutManager(new LinearLayoutManager(requireContext()));
numbersList.setHasFixedSize(true);
numbersList.setAdapter(new SlowListAdapter(NUM_LIST_ITEMS));
return root;
}
Aggregations