mirror of
https://github.com/oxen-io/session-android.git
synced 2024-12-26 09:47:43 +00:00
Minor refactoring
This commit is contained in:
parent
4cc22608aa
commit
4d7b179008
@ -57,15 +57,15 @@ class ContactSelectionListFragment : Fragment(), LoaderManager.LoaderCallbacks<L
|
|||||||
LoaderManager.getInstance(this).initLoader(0, null, this)
|
LoaderManager.getInstance(this).initLoader(0, null, this)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
|
||||||
|
return inflater.inflate(R.layout.contact_selection_list_fragment, container, false)
|
||||||
|
}
|
||||||
|
|
||||||
override fun onStop() {
|
override fun onStop() {
|
||||||
super.onStop()
|
super.onStop()
|
||||||
LoaderManager.getInstance(this).destroyLoader(0)
|
LoaderManager.getInstance(this).destroyLoader(0)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
|
|
||||||
return inflater.inflate(R.layout.contact_selection_list_fragment, container, false)
|
|
||||||
}
|
|
||||||
|
|
||||||
fun setQueryFilter(filter: String?) {
|
fun setQueryFilter(filter: String?) {
|
||||||
cursorFilter = filter
|
cursorFilter = filter
|
||||||
LoaderManager.getInstance(this).restartLoader(0, null, this)
|
LoaderManager.getInstance(this).restartLoader(0, null, this)
|
||||||
@ -101,7 +101,7 @@ class ContactSelectionListFragment : Fragment(), LoaderManager.LoaderCallbacks<L
|
|||||||
private fun update(items: List<ContactSelectionListItem>) {
|
private fun update(items: List<ContactSelectionListItem>) {
|
||||||
if (activity?.isDestroyed == true) {
|
if (activity?.isDestroyed == true) {
|
||||||
Log.e(ContactSelectionListFragment::class.java.name,
|
Log.e(ContactSelectionListFragment::class.java.name,
|
||||||
"Received a loader callback after the fragment was detached from an activity.",
|
"Received a loader callback after the fragment was detached from the activity.",
|
||||||
IllegalStateException())
|
IllegalStateException())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user