PasswordFragment: bring back dividers (#980)

This commit is contained in:
Harsh Shandilya
2020-07-28 16:19:06 +05:30
committed by GitHub
parent a5669c87fd
commit a3b6bf954f

View File

@@ -21,6 +21,7 @@ import androidx.fragment.app.activityViewModels
import androidx.fragment.app.setFragmentResultListener
import androidx.lifecycle.observe
import androidx.preference.PreferenceManager
import androidx.recyclerview.widget.DividerItemDecoration
import androidx.recyclerview.widget.LinearLayoutManager
import com.google.android.material.snackbar.Snackbar
import com.zeapo.pwdstore.databinding.PasswordRecyclerViewBinding
@@ -125,6 +126,7 @@ class PasswordFragment : Fragment(R.layout.password_recycler_view) {
}
val recyclerView = binding.passRecycler
recyclerView.apply {
addItemDecoration(DividerItemDecoration(requireContext(), LinearLayoutManager.VERTICAL))
layoutManager = LinearLayoutManager(requireContext())
itemAnimator = OnOffItemAnimator()
adapter = recyclerAdapter