From 80a4c49c73bb207740f3147501040068811ca0c0 Mon Sep 17 00:00:00 2001 From: Damyan Ivanov Date: Sun, 31 Jan 2021 15:25:08 +0200 Subject: [PATCH] cleanup --- .../mobileledger/ui/patterns/PatternListFragment.java | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/app/src/main/java/net/ktnx/mobileledger/ui/patterns/PatternListFragment.java b/app/src/main/java/net/ktnx/mobileledger/ui/patterns/PatternListFragment.java index 226f846f..3f8dbb13 100644 --- a/app/src/main/java/net/ktnx/mobileledger/ui/patterns/PatternListFragment.java +++ b/app/src/main/java/net/ktnx/mobileledger/ui/patterns/PatternListFragment.java @@ -88,7 +88,7 @@ public class PatternListFragment extends Fragment { PatternHeaderDAO pDao = DB.get() .getPatternDAO(); LiveData> patterns = pDao.getPatterns(); - patterns.observe(getViewLifecycleOwner(), list -> {modelAdapter.setPatterns(list);}); + patterns.observe(getViewLifecycleOwner(), modelAdapter::setPatterns); LinearLayoutManager llm = new LinearLayoutManager(getContext()); llm.setOrientation(RecyclerView.VERTICAL); b.patternList.setLayoutManager(llm); @@ -117,12 +117,6 @@ public class PatternListFragment extends Fragment { }; getLifecycle().addObserver(observer); } - private void fabClicked(View view) { - if (mListener == null) - return; - - mListener.onEditPattern(null); - } /** * This interface must be implemented by activities that contain this * fragment to allow an interaction in this fragment to be communicated -- 2.39.5