From a66e6c302df2be55f470710e9ebe988bfa159ce7 Mon Sep 17 00:00:00 2001 From: M66B Date: Sat, 13 Feb 2016 13:21:18 +0100 Subject: [PATCH] Collect garbage --- app/src/main/java/eu/faircode/netguard/DownloadTask.java | 3 ++- app/src/main/java/eu/faircode/netguard/IAB.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/faircode/netguard/DownloadTask.java b/app/src/main/java/eu/faircode/netguard/DownloadTask.java index bbcf9f10..84539ada 100644 --- a/app/src/main/java/eu/faircode/netguard/DownloadTask.java +++ b/app/src/main/java/eu/faircode/netguard/DownloadTask.java @@ -1,5 +1,6 @@ package eu.faircode.netguard; +import android.app.Activity; import android.app.ProgressDialog; import android.content.Context; import android.content.DialogInterface; @@ -34,7 +35,7 @@ public class DownloadTask extends AsyncTask { void onException(Throwable ex); } - public DownloadTask(Context context, URL url, File file, Listener listener) { + public DownloadTask(Activity context, URL url, File file, Listener listener) { this.context = context; this.url = url; this.file = file; diff --git a/app/src/main/java/eu/faircode/netguard/IAB.java b/app/src/main/java/eu/faircode/netguard/IAB.java index 62af8e65..9bb28904 100644 --- a/app/src/main/java/eu/faircode/netguard/IAB.java +++ b/app/src/main/java/eu/faircode/netguard/IAB.java @@ -52,7 +52,7 @@ public class IAB implements ServiceConnection { } public IAB(Delegate delegate, Context context) { - this.context = context; + this.context = context.getApplicationContext(); this.delegate = delegate; }