From bea6318473d9c14efafe0c7c0d64e3150722084f Mon Sep 17 00:00:00 2001 From: keep2iron <497881309@qq.com> Date: Wed, 3 Jul 2019 17:43:29 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9ProgressDialogSubscriber?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../github/keep2iron/pomelo/ProgressDialogSubscriber.kt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pomelo/src/main/java/io/github/keep2iron/pomelo/ProgressDialogSubscriber.kt b/pomelo/src/main/java/io/github/keep2iron/pomelo/ProgressDialogSubscriber.kt index 3931531..d0c3b5f 100644 --- a/pomelo/src/main/java/io/github/keep2iron/pomelo/ProgressDialogSubscriber.kt +++ b/pomelo/src/main/java/io/github/keep2iron/pomelo/ProgressDialogSubscriber.kt @@ -12,11 +12,12 @@ import io.reactivex.disposables.Disposable * @version 1.0 * @since 2017/12/27 17:46 */ -abstract class ProgressDialogSubscriber( +open class ProgressDialogSubscriber( activity: Activity, - private val controller: ProgressDialogController -) : AndroidSubscriber() { - private var activityRef = WeakReference(activity) + private val controller: ProgressDialogController, + block: AndroidSubscriber.() -> Unit +) : AndroidSubscriber(block) { + private var activityRef = WeakReference(activity) @CallSuper override fun onSubscribe(disposable: Disposable) {