Address more coroutine scope leaks

This commit is contained in:
arkon
2021-01-07 18:15:57 -05:00
parent 36f81b4a62
commit 6fb7a85e8a
23 changed files with 85 additions and 83 deletions

View File

@@ -7,9 +7,7 @@ import android.view.LayoutInflater
import android.view.View
import android.widget.LinearLayout
import eu.kanade.tachiyomi.databinding.DownloadCustomAmountBinding
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.Job
import kotlinx.coroutines.MainScope
import kotlinx.coroutines.flow.launchIn
import kotlinx.coroutines.flow.onEach
import reactivecircus.flowbinding.android.widget.textChanges
@@ -37,7 +35,7 @@ class DialogCustomDownloadView @JvmOverloads constructor(context: Context, attrs
*/
private var max = 0
private val scope = CoroutineScope(Job() + Dispatchers.Main)
private val scope = MainScope()
private val binding: DownloadCustomAmountBinding