diff options
Diffstat (limited to 'app/src/play')
-rw-r--r-- | app/src/play/java/de/danoeh/antennapod/dialog/CustomMRControllerDialog.java | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/app/src/play/java/de/danoeh/antennapod/dialog/CustomMRControllerDialog.java b/app/src/play/java/de/danoeh/antennapod/dialog/CustomMRControllerDialog.java index 3e1576261..eab085479 100644 --- a/app/src/play/java/de/danoeh/antennapod/dialog/CustomMRControllerDialog.java +++ b/app/src/play/java/de/danoeh/antennapod/dialog/CustomMRControllerDialog.java @@ -42,10 +42,10 @@ import java.util.concurrent.ExecutionException; import de.danoeh.antennapod.R; import de.danoeh.antennapod.core.glide.ApGlideSettings; -import rx.Observable; -import rx.Subscription; -import rx.android.schedulers.AndroidSchedulers; -import rx.schedulers.Schedulers; +import io.reactivex.Observable; +import io.reactivex.android.schedulers.AndroidSchedulers; +import io.reactivex.disposables.Disposable; +import io.reactivex.schedulers.Schedulers; public class CustomMRControllerDialog extends MediaRouteControllerDialog { public static final String TAG = "CustomMRContrDialog"; @@ -61,7 +61,7 @@ public class CustomMRControllerDialog extends MediaRouteControllerDialog { private boolean viewsCreated = false; - private Subscription fetchArtSubscription; + private Disposable fetchArtSubscription; private MediaControllerCompat mediaController; private MediaControllerCompat.Callback mediaControllerCallback; @@ -328,7 +328,7 @@ public class CustomMRControllerDialog extends MediaRouteControllerDialog { @Override public void onDetachedFromWindow() { if (fetchArtSubscription != null) { - fetchArtSubscription.unsubscribe(); + fetchArtSubscription.dispose(); fetchArtSubscription = null; } super.onDetachedFromWindow(); @@ -397,11 +397,11 @@ public class CustomMRControllerDialog extends MediaRouteControllerDialog { } if (fetchArtSubscription != null) { - fetchArtSubscription.unsubscribe(); + fetchArtSubscription.dispose(); } fetchArtSubscription = Observable.fromCallable(() -> fetchArt(description)) - .subscribeOn(Schedulers.newThread()) + .subscribeOn(Schedulers.io()) .observeOn(AndroidSchedulers.mainThread()) .subscribe(result -> { fetchArtSubscription = null; |