commit 667f37e301c06f052cad2da974b9056970d41c32 Author: Hans-Christoph Steiner hans@eds.org Date: Mon Oct 7 17:58:38 2019 +0200
run Android Studio's Optimize Imports on whole project --- .../torproject/android/mini/MiniMainActivity.java | 14 ----- .../torproject/android/mini/OnBootReceiver.java | 5 +- .../org/torproject/android/mini/OrbotMiniApp.java | 7 +-- .../android/mini/settings/LocaleHelper.java | 1 - .../android/mini/settings/SettingsPreferences.java | 1 - .../android/mini/ui/AppConfigActivity.java | 6 -- .../android/mini/ui/AppManagerActivity.java | 25 ++++---- .../mini/ui/onboarding/CustomSlideBigText.java | 1 - .../mini/ui/onboarding/OnboardingActivity.java | 2 - .../android/mini/vpn/VPNEnableActivity.java | 7 +-- .../org/torproject/android/OnBootReceiver.java | 3 +- .../main/java/org/torproject/android/OrbotApp.java | 3 - .../org/torproject/android/OrbotMainActivity.java | 69 +++++++++++----------- .../torproject/android/settings/LocaleHelper.java | 1 - .../android/settings/SettingsPreferences.java | 1 - .../torproject/android/ui/AppManagerActivity.java | 25 ++++---- .../torproject/android/ui/VPNEnableActivity.java | 7 +-- .../ui/hiddenservices/ClientCookiesActivity.java | 2 - .../ui/hiddenservices/HiddenServicesActivity.java | 1 - .../ui/hiddenservices/adapters/BackupAdapter.java | 1 - .../adapters/ClientCookiesAdapter.java | 1 - .../hiddenservices/adapters/OnionListAdapter.java | 1 - .../ui/hiddenservices/backup/BackupUtils.java | 1 - .../ui/hiddenservices/dialogs/AddCookieDialog.java | 1 - .../dialogs/CookieActionsDialog.java | 1 - .../hiddenservices/dialogs/CookieDeleteDialog.java | 1 - .../ui/hiddenservices/dialogs/HSActionsDialog.java | 1 - .../ui/hiddenservices/dialogs/HSCookieDialog.java | 2 - .../ui/hiddenservices/dialogs/HSDataDialog.java | 1 - .../ui/hiddenservices/dialogs/HSDeleteDialog.java | 1 - .../dialogs/SelectCookieBackupDialog.java | 1 - .../dialogs/SelectHSBackupDialog.java | 1 - .../permissions/PermissionManager.java | 1 - .../providers/CookieContentProvider.java | 1 - .../providers/HSContentProvider.java | 1 - .../ui/onboarding/BridgeWizardActivity.java | 1 - .../android/ui/onboarding/CustomSlideBigText.java | 1 - .../android/ui/onboarding/OnboardingActivity.java | 4 +- .../android/control/TorControlConnection.java | 2 - .../android/service/StartTorReceiver.java | 1 - .../android/service/TorEventHandler.java | 16 +---- .../org/torproject/android/service/TorService.java | 7 +-- .../android/service/util/CustomShell.java | 3 - .../service/util/CustomTorResourceInstaller.java | 1 - .../android/service/util/NativeLoader.java | 2 - .../android/service/util/PortForwarder.java | 1 - .../android/service/util/TCPSourceApp.java | 13 ++-- .../android/service/util/TorServiceUtils.java | 1 - .../android/service/vpn/OrbotVpnManager.java | 5 -- .../android/service/vpn/TorVpnService.java | 1 - .../torproject/android/service/vpn/Tun2Socks.java | 2 - 51 files changed, 78 insertions(+), 181 deletions(-)
diff --git a/app-mini/src/main/java/org/torproject/android/mini/MiniMainActivity.java b/app-mini/src/main/java/org/torproject/android/mini/MiniMainActivity.java index 54cf23a9..6710778d 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/MiniMainActivity.java +++ b/app-mini/src/main/java/org/torproject/android/mini/MiniMainActivity.java @@ -3,7 +3,6 @@
package org.torproject.android.mini;
-import android.Manifest; import android.app.ActivityManager; import android.app.ActivityManager.RunningServiceInfo; import android.app.AlertDialog; @@ -14,13 +13,10 @@ import android.content.IntentFilter; import android.content.SharedPreferences; import android.content.SharedPreferences.Editor; import android.content.pm.ApplicationInfo; -import android.content.pm.PackageInfo; import android.content.pm.PackageManager; import android.content.pm.PackageManager.NameNotFoundException; import android.graphics.Bitmap; -import android.graphics.BitmapFactory; import android.graphics.Canvas; -import android.graphics.drawable.AdaptiveIconDrawable; import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.Drawable; import android.net.Uri; @@ -47,15 +43,11 @@ import android.view.View; import android.view.View.OnLongClickListener; import android.view.ViewGroup; import android.view.animation.AccelerateInterpolator; -import android.widget.Button; import android.widget.CompoundButton; import android.widget.ImageView; -import android.widget.LinearLayout; import android.widget.TextView; - import com.google.zxing.integration.android.IntentIntegrator; import com.google.zxing.integration.android.IntentResult; - import org.json.JSONArray; import org.torproject.android.mini.settings.Languages; import org.torproject.android.mini.settings.LocaleHelper; @@ -77,19 +69,13 @@ import org.torproject.android.service.vpn.VpnPrefs; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; -import java.io.UnsupportedEncodingException; import java.net.URLDecoder; -import java.net.URLEncoder; import java.text.NumberFormat; import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.Comparator; import java.util.Locale; import java.util.StringTokenizer;
import static org.torproject.android.mini.MainConstants.RESULT_CLOSE_ALL; -import static org.torproject.android.mini.MainConstants.URL_TOR_CHECK; import static org.torproject.android.service.vpn.VpnPrefs.PREFS_KEY_TORIFIED; import static org.torproject.android.service.vpn.VpnUtils.getSharedPrefs;
diff --git a/app-mini/src/main/java/org/torproject/android/mini/OnBootReceiver.java b/app-mini/src/main/java/org/torproject/android/mini/OnBootReceiver.java index 6ddaf47e..d2dab5d8 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/OnBootReceiver.java +++ b/app-mini/src/main/java/org/torproject/android/mini/OnBootReceiver.java @@ -5,11 +5,10 @@ import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.os.Build; - -import org.torproject.android.service.util.Prefs; +import org.torproject.android.mini.vpn.VPNEnableActivity; import org.torproject.android.service.TorService; import org.torproject.android.service.TorServiceConstants; -import org.torproject.android.mini.vpn.VPNEnableActivity; +import org.torproject.android.service.util.Prefs;
public class OnBootReceiver extends BroadcastReceiver {
diff --git a/app-mini/src/main/java/org/torproject/android/mini/OrbotMiniApp.java b/app-mini/src/main/java/org/torproject/android/mini/OrbotMiniApp.java index 95e867cf..80b34d6d 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/OrbotMiniApp.java +++ b/app-mini/src/main/java/org/torproject/android/mini/OrbotMiniApp.java @@ -12,16 +12,13 @@ import android.content.Intent; import android.content.pm.PackageManager; import android.content.res.Configuration; import android.support.v4.app.NotificationCompat; - import com.github.javiersantos.appupdater.AppUpdater; import com.github.javiersantos.appupdater.enums.Display; import com.github.javiersantos.appupdater.enums.UpdateFrom; - -import org.torproject.android.service.OrbotConstants; -import org.torproject.android.service.util.Prefs; - import org.torproject.android.mini.settings.Languages; import org.torproject.android.mini.settings.LocaleHelper; +import org.torproject.android.service.OrbotConstants; +import org.torproject.android.service.util.Prefs;
import java.util.Locale;
diff --git a/app-mini/src/main/java/org/torproject/android/mini/settings/LocaleHelper.java b/app-mini/src/main/java/org/torproject/android/mini/settings/LocaleHelper.java index 2d84e988..e4b29be2 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/settings/LocaleHelper.java +++ b/app-mini/src/main/java/org/torproject/android/mini/settings/LocaleHelper.java @@ -5,7 +5,6 @@ import android.content.Context; import android.content.res.Configuration; import android.content.res.Resources; import android.os.Build; - import org.torproject.android.service.util.Prefs;
import java.util.Locale; diff --git a/app-mini/src/main/java/org/torproject/android/mini/settings/SettingsPreferences.java b/app-mini/src/main/java/org/torproject/android/mini/settings/SettingsPreferences.java index f551f306..e5b5074b 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/settings/SettingsPreferences.java +++ b/app-mini/src/main/java/org/torproject/android/mini/settings/SettingsPreferences.java @@ -15,7 +15,6 @@ import android.preference.PreferenceCategory; import android.preference.PreferenceScreen; import android.view.inputmethod.EditorInfo; import android.widget.EditText; - import org.torproject.android.mini.R;
public class SettingsPreferences extends PreferenceActivity { diff --git a/app-mini/src/main/java/org/torproject/android/mini/ui/AppConfigActivity.java b/app-mini/src/main/java/org/torproject/android/mini/ui/AppConfigActivity.java index d57674d3..a8488e3d 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/ui/AppConfigActivity.java +++ b/app-mini/src/main/java/org/torproject/android/mini/ui/AppConfigActivity.java @@ -4,19 +4,13 @@ import android.content.Intent; import android.content.SharedPreferences; import android.content.pm.ApplicationInfo; import android.os.Bundle; -import android.support.design.widget.FloatingActionButton; -import android.support.design.widget.Snackbar; import android.support.v7.app.AppCompatActivity; import android.support.v7.widget.Toolbar; import android.view.Menu; import android.view.MenuInflater; import android.view.MenuItem; -import android.view.View; import android.widget.CompoundButton; import android.widget.Switch; - -import org.torproject.android.mini.MainConstants; -import org.torproject.android.mini.MiniMainActivity; import org.torproject.android.mini.R; import org.torproject.android.service.OrbotConstants; import org.torproject.android.service.util.TorServiceUtils; diff --git a/app-mini/src/main/java/org/torproject/android/mini/ui/AppManagerActivity.java b/app-mini/src/main/java/org/torproject/android/mini/ui/AppManagerActivity.java index ea66d7f2..27425bce 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/ui/AppManagerActivity.java +++ b/app-mini/src/main/java/org/torproject/android/mini/ui/AppManagerActivity.java @@ -3,19 +3,6 @@
package org.torproject.android.mini.ui;
-import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.Comparator; -import java.util.Iterator; -import java.util.List; -import java.util.StringTokenizer; - -import org.torproject.android.mini.R; -import org.torproject.android.service.OrbotConstants; -import org.torproject.android.service.util.TorServiceUtils; -import org.torproject.android.service.vpn.TorifiedApp; - import android.Manifest; import android.content.Intent; import android.content.SharedPreferences; @@ -34,12 +21,22 @@ import android.view.View; import android.view.View.OnClickListener; import android.view.ViewGroup; import android.widget.ArrayAdapter; -import android.widget.CheckBox; import android.widget.GridView; import android.widget.ImageView; import android.widget.ListAdapter; import android.widget.ProgressBar; import android.widget.TextView; +import org.torproject.android.mini.R; +import org.torproject.android.service.OrbotConstants; +import org.torproject.android.service.util.TorServiceUtils; +import org.torproject.android.service.vpn.TorifiedApp; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.Iterator; +import java.util.List; +import java.util.StringTokenizer;
import static org.torproject.android.service.vpn.VpnPrefs.PREFS_KEY_TORIFIED;
diff --git a/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/CustomSlideBigText.java b/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/CustomSlideBigText.java index 133b3241..a370c6f1 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/CustomSlideBigText.java +++ b/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/CustomSlideBigText.java @@ -9,7 +9,6 @@ import android.view.View; import android.view.ViewGroup; import android.widget.Button; import android.widget.TextView; - import org.torproject.android.mini.R;
diff --git a/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/OnboardingActivity.java b/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/OnboardingActivity.java index f6531a7d..5e661999 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/OnboardingActivity.java +++ b/app-mini/src/main/java/org/torproject/android/mini/ui/onboarding/OnboardingActivity.java @@ -4,9 +4,7 @@ import android.content.Context; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v4.app.Fragment; - import com.github.paolorotolo.appintro.AppIntro; - import org.torproject.android.mini.R; import org.torproject.android.mini.settings.LocaleHelper;
diff --git a/app-mini/src/main/java/org/torproject/android/mini/vpn/VPNEnableActivity.java b/app-mini/src/main/java/org/torproject/android/mini/vpn/VPNEnableActivity.java index 29492d3e..c252852b 100644 --- a/app-mini/src/main/java/org/torproject/android/mini/vpn/VPNEnableActivity.java +++ b/app-mini/src/main/java/org/torproject/android/mini/vpn/VPNEnableActivity.java @@ -1,9 +1,5 @@ package org.torproject.android.mini.vpn;
-import org.torproject.android.service.util.Prefs; -import org.torproject.android.service.TorService; -import org.torproject.android.service.TorServiceConstants; - import android.content.Intent; import android.net.VpnService; import android.os.Build; @@ -12,6 +8,9 @@ import android.os.Handler; import android.support.v7.app.AppCompatActivity; import android.util.Log; import android.view.Window; +import org.torproject.android.service.TorService; +import org.torproject.android.service.TorServiceConstants; +import org.torproject.android.service.util.Prefs;
/** * To combat background service being stopped/swiped diff --git a/app/src/main/java/org/torproject/android/OnBootReceiver.java b/app/src/main/java/org/torproject/android/OnBootReceiver.java index b18aff78..6a3cc6fa 100644 --- a/app/src/main/java/org/torproject/android/OnBootReceiver.java +++ b/app/src/main/java/org/torproject/android/OnBootReceiver.java @@ -5,10 +5,9 @@ import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.os.Build; - -import org.torproject.android.service.util.Prefs; import org.torproject.android.service.TorService; import org.torproject.android.service.TorServiceConstants; +import org.torproject.android.service.util.Prefs; import org.torproject.android.ui.VPNEnableActivity;
public class OnBootReceiver extends BroadcastReceiver { diff --git a/app/src/main/java/org/torproject/android/OrbotApp.java b/app/src/main/java/org/torproject/android/OrbotApp.java index dbd9d469..f022f611 100644 --- a/app/src/main/java/org/torproject/android/OrbotApp.java +++ b/app/src/main/java/org/torproject/android/OrbotApp.java @@ -12,14 +12,11 @@ import android.content.Intent; import android.content.pm.PackageManager; import android.content.res.Configuration; import android.support.v4.app.NotificationCompat; - import com.github.javiersantos.appupdater.AppUpdater; import com.github.javiersantos.appupdater.enums.Display; import com.github.javiersantos.appupdater.enums.UpdateFrom; - import org.torproject.android.service.OrbotConstants; import org.torproject.android.service.util.Prefs; - import org.torproject.android.settings.Languages; import org.torproject.android.settings.LocaleHelper;
diff --git a/app/src/main/java/org/torproject/android/OrbotMainActivity.java b/app/src/main/java/org/torproject/android/OrbotMainActivity.java index 91683ea9..82a0cef9 100644 --- a/app/src/main/java/org/torproject/android/OrbotMainActivity.java +++ b/app/src/main/java/org/torproject/android/OrbotMainActivity.java @@ -3,40 +3,6 @@
package org.torproject.android;
-import java.io.BufferedReader; -import java.io.File; -import java.io.IOException; -import java.io.InputStreamReader; -import java.io.UnsupportedEncodingException; -import java.net.URLDecoder; -import java.net.URLEncoder; -import java.text.NumberFormat; -import java.util.ArrayList; -import java.util.Locale; -import java.util.StringTokenizer; - -import org.json.JSONArray; -import org.torproject.android.service.OrbotConstants; -import org.torproject.android.service.util.Prefs; -import org.torproject.android.service.TorService; -import org.torproject.android.service.TorServiceConstants; -import org.torproject.android.service.util.TorServiceUtils; -import org.torproject.android.service.vpn.VpnConstants; -import org.torproject.android.service.vpn.VpnPrefs; -import org.torproject.android.settings.Languages; -import org.torproject.android.settings.LocaleHelper; -import org.torproject.android.settings.SettingsPreferences; -import org.torproject.android.ui.AppManagerActivity; -import org.torproject.android.ui.Rotate3dAnimation; -import org.torproject.android.ui.onboarding.BridgeWizardActivity; -import org.torproject.android.ui.onboarding.OnboardingActivity; -import org.torproject.android.ui.hiddenservices.ClientCookiesActivity; -import org.torproject.android.ui.hiddenservices.HiddenServicesActivity; -import org.torproject.android.ui.hiddenservices.backup.BackupUtils; -import org.torproject.android.ui.hiddenservices.permissions.PermissionManager; -import org.torproject.android.ui.hiddenservices.providers.HSContentProvider; -import org.torproject.android.ui.VPNEnableActivity; - import android.app.ActivityManager; import android.app.ActivityManager.RunningServiceInfo; import android.app.AlertDialog; @@ -84,12 +50,43 @@ import android.widget.LinearLayout; import android.widget.Spinner; import android.widget.TextView; import android.widget.Toast; - import com.google.zxing.integration.android.IntentIntegrator; import com.google.zxing.integration.android.IntentResult; - +import org.json.JSONArray; +import org.torproject.android.service.OrbotConstants; +import org.torproject.android.service.TorService; +import org.torproject.android.service.TorServiceConstants; +import org.torproject.android.service.util.Prefs; +import org.torproject.android.service.util.TorServiceUtils; +import org.torproject.android.service.vpn.VpnConstants; +import org.torproject.android.service.vpn.VpnPrefs; +import org.torproject.android.settings.Languages; +import org.torproject.android.settings.LocaleHelper; +import org.torproject.android.settings.SettingsPreferences; +import org.torproject.android.ui.AppManagerActivity; +import org.torproject.android.ui.Rotate3dAnimation; +import org.torproject.android.ui.VPNEnableActivity; +import org.torproject.android.ui.hiddenservices.ClientCookiesActivity; +import org.torproject.android.ui.hiddenservices.HiddenServicesActivity; +import org.torproject.android.ui.hiddenservices.backup.BackupUtils; +import org.torproject.android.ui.hiddenservices.permissions.PermissionManager; +import org.torproject.android.ui.hiddenservices.providers.HSContentProvider; +import org.torproject.android.ui.onboarding.BridgeWizardActivity; +import org.torproject.android.ui.onboarding.OnboardingActivity; import pl.bclogic.pulsator4droid.library.PulsatorLayout;
+import java.io.BufferedReader; +import java.io.File; +import java.io.IOException; +import java.io.InputStreamReader; +import java.io.UnsupportedEncodingException; +import java.net.URLDecoder; +import java.net.URLEncoder; +import java.text.NumberFormat; +import java.util.ArrayList; +import java.util.Locale; +import java.util.StringTokenizer; + import static android.support.v4.content.FileProvider.getUriForFile; import static org.torproject.android.MainConstants.COUNTRY_CODES; import static org.torproject.android.MainConstants.RESULT_CLOSE_ALL; diff --git a/app/src/main/java/org/torproject/android/settings/LocaleHelper.java b/app/src/main/java/org/torproject/android/settings/LocaleHelper.java index e1f496e4..ea3fde93 100644 --- a/app/src/main/java/org/torproject/android/settings/LocaleHelper.java +++ b/app/src/main/java/org/torproject/android/settings/LocaleHelper.java @@ -5,7 +5,6 @@ import android.content.Context; import android.content.res.Configuration; import android.content.res.Resources; import android.os.Build; - import org.torproject.android.service.util.Prefs;
import java.util.Locale; diff --git a/app/src/main/java/org/torproject/android/settings/SettingsPreferences.java b/app/src/main/java/org/torproject/android/settings/SettingsPreferences.java index 040b7b57..2af632ee 100644 --- a/app/src/main/java/org/torproject/android/settings/SettingsPreferences.java +++ b/app/src/main/java/org/torproject/android/settings/SettingsPreferences.java @@ -15,7 +15,6 @@ import android.preference.PreferenceCategory; import android.preference.PreferenceScreen; import android.view.inputmethod.EditorInfo; import android.widget.EditText; - import org.torproject.android.R;
public class SettingsPreferences extends PreferenceActivity { diff --git a/app/src/main/java/org/torproject/android/ui/AppManagerActivity.java b/app/src/main/java/org/torproject/android/ui/AppManagerActivity.java index 56b83430..d5ea6f8e 100644 --- a/app/src/main/java/org/torproject/android/ui/AppManagerActivity.java +++ b/app/src/main/java/org/torproject/android/ui/AppManagerActivity.java @@ -3,19 +3,6 @@
package org.torproject.android.ui;
-import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.Comparator; -import java.util.Iterator; -import java.util.List; -import java.util.StringTokenizer; - -import org.torproject.android.service.OrbotConstants; -import org.torproject.android.R; -import org.torproject.android.service.util.TorServiceUtils; -import org.torproject.android.service.vpn.TorifiedApp; - import android.Manifest; import android.content.Intent; import android.content.SharedPreferences; @@ -40,6 +27,18 @@ import android.widget.ImageView; import android.widget.ListAdapter; import android.widget.ProgressBar; import android.widget.TextView; +import org.torproject.android.R; +import org.torproject.android.service.OrbotConstants; +import org.torproject.android.service.util.TorServiceUtils; +import org.torproject.android.service.vpn.TorifiedApp; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.Comparator; +import java.util.Iterator; +import java.util.List; +import java.util.StringTokenizer;
import static org.torproject.android.service.vpn.VpnPrefs.PREFS_KEY_TORIFIED;
diff --git a/app/src/main/java/org/torproject/android/ui/VPNEnableActivity.java b/app/src/main/java/org/torproject/android/ui/VPNEnableActivity.java index fd8df38c..09bdf84a 100644 --- a/app/src/main/java/org/torproject/android/ui/VPNEnableActivity.java +++ b/app/src/main/java/org/torproject/android/ui/VPNEnableActivity.java @@ -1,9 +1,5 @@ package org.torproject.android.ui;
-import org.torproject.android.service.util.Prefs; -import org.torproject.android.service.TorService; -import org.torproject.android.service.TorServiceConstants; - import android.content.Intent; import android.net.VpnService; import android.os.Build; @@ -12,6 +8,9 @@ import android.os.Handler; import android.support.v7.app.AppCompatActivity; import android.util.Log; import android.view.Window; +import org.torproject.android.service.TorService; +import org.torproject.android.service.TorServiceConstants; +import org.torproject.android.service.util.Prefs;
/** * To combat background service being stopped/swiped diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/ClientCookiesActivity.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/ClientCookiesActivity.java index e6939800..8ff14fbb 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/ClientCookiesActivity.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/ClientCookiesActivity.java @@ -18,10 +18,8 @@ import android.view.View; import android.widget.AdapterView; import android.widget.ListView; import android.widget.Toast; - import com.google.zxing.integration.android.IntentIntegrator; import com.google.zxing.integration.android.IntentResult; - import org.json.JSONException; import org.json.JSONObject; import org.torproject.android.R; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/HiddenServicesActivity.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/HiddenServicesActivity.java index d7c1f313..f41babdf 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/HiddenServicesActivity.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/HiddenServicesActivity.java @@ -20,7 +20,6 @@ import android.widget.ArrayAdapter; import android.widget.ListView; import android.widget.Spinner; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.settings.LocaleHelper; import org.torproject.android.ui.hiddenservices.adapters.OnionListAdapter; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/BackupAdapter.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/BackupAdapter.java index 196023b3..272dbf36 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/BackupAdapter.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/BackupAdapter.java @@ -6,7 +6,6 @@ import android.view.View; import android.view.ViewGroup; import android.widget.ArrayAdapter; import android.widget.TextView; - import org.torproject.android.R;
import java.io.File; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/ClientCookiesAdapter.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/ClientCookiesAdapter.java index bbc317a6..10108ba8 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/ClientCookiesAdapter.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/ClientCookiesAdapter.java @@ -12,7 +12,6 @@ import android.widget.CompoundButton; import android.widget.Switch; import android.widget.TextView; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.providers.CookieContentProvider;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java index 9824c773..a41befdf 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java @@ -12,7 +12,6 @@ import android.widget.CompoundButton; import android.widget.Switch; import android.widget.TextView; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.providers.HSContentProvider;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/backup/BackupUtils.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/backup/BackupUtils.java index a4790dd8..8efa47d3 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/backup/BackupUtils.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/backup/BackupUtils.java @@ -7,7 +7,6 @@ import android.database.Cursor; import android.net.Uri; import android.os.ParcelFileDescriptor; import android.widget.Toast; - import org.json.JSONException; import org.json.JSONObject; import org.torproject.android.R; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/AddCookieDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/AddCookieDialog.java index 8441d53f..af8922d6 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/AddCookieDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/AddCookieDialog.java @@ -12,7 +12,6 @@ import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.providers.CookieContentProvider;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieActionsDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieActionsDialog.java index 7b5a2cfe..03dddbd6 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieActionsDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieActionsDialog.java @@ -12,7 +12,6 @@ import android.support.v7.app.AlertDialog; import android.view.View; import android.widget.Button; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.backup.BackupUtils; import org.torproject.android.ui.hiddenservices.permissions.PermissionManager; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieDeleteDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieDeleteDialog.java index 60c4d8e3..d2b1220d 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieDeleteDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/CookieDeleteDialog.java @@ -8,7 +8,6 @@ import android.os.Bundle; import android.support.annotation.NonNull; import android.support.v4.app.DialogFragment; import android.support.v7.app.AlertDialog; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.providers.CookieContentProvider;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSActionsDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSActionsDialog.java index 5be76917..ce77fd2a 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSActionsDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSActionsDialog.java @@ -14,7 +14,6 @@ import android.support.v7.app.AlertDialog; import android.view.View; import android.widget.Button; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.backup.BackupUtils; import org.torproject.android.ui.hiddenservices.permissions.PermissionManager; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSCookieDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSCookieDialog.java index 39c1b510..eb9ee9ce 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSCookieDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSCookieDialog.java @@ -12,9 +12,7 @@ import android.view.View; import android.widget.Button; import android.widget.TextView; import android.widget.Toast; - import com.google.zxing.integration.android.IntentIntegrator; - import org.json.JSONException; import org.json.JSONObject; import org.torproject.android.R; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDataDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDataDialog.java index 01e09dff..d7ba35e3 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDataDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDataDialog.java @@ -13,7 +13,6 @@ import android.widget.Button; import android.widget.CheckBox; import android.widget.EditText; import android.widget.Toast; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.providers.HSContentProvider;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDeleteDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDeleteDialog.java index ac5df743..cf38ffab 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDeleteDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/HSDeleteDialog.java @@ -8,7 +8,6 @@ import android.os.Bundle; import android.support.annotation.NonNull; import android.support.v4.app.DialogFragment; import android.support.v7.app.AlertDialog; - import org.torproject.android.R; import org.torproject.android.service.TorServiceConstants; import org.torproject.android.ui.hiddenservices.providers.HSContentProvider; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectCookieBackupDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectCookieBackupDialog.java index de5b7848..af362358 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectCookieBackupDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectCookieBackupDialog.java @@ -9,7 +9,6 @@ import android.support.v7.app.AlertDialog; import android.view.View; import android.widget.AdapterView; import android.widget.ListView; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.adapters.BackupAdapter; import org.torproject.android.ui.hiddenservices.backup.BackupUtils; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectHSBackupDialog.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectHSBackupDialog.java index a6e3bac9..cb0c2bfe 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectHSBackupDialog.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/dialogs/SelectHSBackupDialog.java @@ -9,7 +9,6 @@ import android.support.v7.app.AlertDialog; import android.view.View; import android.widget.AdapterView; import android.widget.ListView; - import org.torproject.android.R; import org.torproject.android.ui.hiddenservices.adapters.BackupAdapter; import org.torproject.android.ui.hiddenservices.backup.BackupUtils; diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/permissions/PermissionManager.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/permissions/PermissionManager.java index a9df5a95..3ee11ec8 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/permissions/PermissionManager.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/permissions/PermissionManager.java @@ -15,7 +15,6 @@ import android.support.design.widget.Snackbar; import android.support.v4.app.ActivityCompat; import android.support.v4.app.FragmentActivity; import android.view.View; - import org.torproject.android.R;
public class PermissionManager { diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/CookieContentProvider.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/CookieContentProvider.java index f420a6d8..1f31b9cb 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/CookieContentProvider.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/CookieContentProvider.java @@ -11,7 +11,6 @@ import android.net.Uri; import android.provider.BaseColumns; import android.support.annotation.NonNull; import android.support.annotation.Nullable; - import org.torproject.android.ui.hiddenservices.database.HSDatabase;
diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/HSContentProvider.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/HSContentProvider.java index d7b558fd..07641ea0 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/HSContentProvider.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/providers/HSContentProvider.java @@ -11,7 +11,6 @@ import android.net.Uri; import android.provider.BaseColumns; import android.support.annotation.NonNull; import android.support.annotation.Nullable; - import org.torproject.android.ui.hiddenservices.database.HSDatabase;
diff --git a/app/src/main/java/org/torproject/android/ui/onboarding/BridgeWizardActivity.java b/app/src/main/java/org/torproject/android/ui/onboarding/BridgeWizardActivity.java index cd43ea0c..15216333 100644 --- a/app/src/main/java/org/torproject/android/ui/onboarding/BridgeWizardActivity.java +++ b/app/src/main/java/org/torproject/android/ui/onboarding/BridgeWizardActivity.java @@ -15,7 +15,6 @@ import android.view.MenuItem; import android.view.View; import android.widget.RadioButton; import android.widget.TextView; - import org.torproject.android.R; import org.torproject.android.service.util.Prefs; import org.torproject.android.settings.LocaleHelper; diff --git a/app/src/main/java/org/torproject/android/ui/onboarding/CustomSlideBigText.java b/app/src/main/java/org/torproject/android/ui/onboarding/CustomSlideBigText.java index 35f5a55a..2ed1c01c 100644 --- a/app/src/main/java/org/torproject/android/ui/onboarding/CustomSlideBigText.java +++ b/app/src/main/java/org/torproject/android/ui/onboarding/CustomSlideBigText.java @@ -9,7 +9,6 @@ import android.view.View; import android.view.ViewGroup; import android.widget.Button; import android.widget.TextView; - import org.torproject.android.R;
public class CustomSlideBigText extends Fragment { diff --git a/app/src/main/java/org/torproject/android/ui/onboarding/OnboardingActivity.java b/app/src/main/java/org/torproject/android/ui/onboarding/OnboardingActivity.java index da473ef1..88359434 100644 --- a/app/src/main/java/org/torproject/android/ui/onboarding/OnboardingActivity.java +++ b/app/src/main/java/org/torproject/android/ui/onboarding/OnboardingActivity.java @@ -6,14 +6,12 @@ import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v4.app.Fragment; import android.view.View; - import com.github.paolorotolo.appintro.AppIntro; - import org.torproject.android.R; import org.torproject.android.settings.LocaleHelper; import org.torproject.android.ui.AppManagerActivity; -import org.torproject.android.ui.hiddenservices.permissions.PermissionManager; import org.torproject.android.ui.VPNEnableActivity; +import org.torproject.android.ui.hiddenservices.permissions.PermissionManager;
public class OnboardingActivity extends AppIntro {
diff --git a/orbotservice/src/main/java/org/torproject/android/control/TorControlConnection.java b/orbotservice/src/main/java/org/torproject/android/control/TorControlConnection.java index 4f1fe95b..52f9be49 100644 --- a/orbotservice/src/main/java/org/torproject/android/control/TorControlConnection.java +++ b/orbotservice/src/main/java/org/torproject/android/control/TorControlConnection.java @@ -13,7 +13,6 @@ import java.io.PrintWriter; import java.io.Reader; import java.io.Writer; import java.net.Socket; -import java.net.SocketException; import java.util.ArrayList; import java.util.Collection; import java.util.HashMap; @@ -22,7 +21,6 @@ import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.StringTokenizer; -import java.util.concurrent.CancellationException;
/** A connection to a running Tor process as specified in control-spec.txt. */ public class TorControlConnection implements TorControlCommands { diff --git a/orbotservice/src/main/java/org/torproject/android/service/StartTorReceiver.java b/orbotservice/src/main/java/org/torproject/android/service/StartTorReceiver.java index 0876174b..b6f96789 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/StartTorReceiver.java +++ b/orbotservice/src/main/java/org/torproject/android/service/StartTorReceiver.java @@ -6,7 +6,6 @@ import android.content.Context; import android.content.Intent; import android.os.Build; import android.text.TextUtils; - import org.torproject.android.service.util.Prefs;
diff --git a/orbotservice/src/main/java/org/torproject/android/service/TorEventHandler.java b/orbotservice/src/main/java/org/torproject/android/service/TorEventHandler.java index ae2841d9..62f14308 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/TorEventHandler.java +++ b/orbotservice/src/main/java/org/torproject/android/service/TorEventHandler.java @@ -1,27 +1,15 @@ package org.torproject.android.service;
import android.text.TextUtils; +import org.torproject.android.control.EventHandler; +import org.torproject.android.service.util.Prefs;
-import org.json.JSONArray; -import org.json.JSONObject; - -import java.io.BufferedReader; -import java.io.InputStream; -import java.io.InputStreamReader; -import java.net.InetSocketAddress; -import java.net.Proxy; -import java.net.URL; -import java.net.URLConnection; import java.text.NumberFormat; import java.util.HashMap; import java.util.List; import java.util.Locale; import java.util.StringTokenizer;
- -import org.torproject.android.control.EventHandler; -import org.torproject.android.service.util.Prefs; - /** * Created by n8fr8 on 9/25/16. */ diff --git a/orbotservice/src/main/java/org/torproject/android/service/TorService.java b/orbotservice/src/main/java/org/torproject/android/service/TorService.java index a566b6d4..e2eb9589 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/TorService.java +++ b/orbotservice/src/main/java/org/torproject/android/service/TorService.java @@ -38,9 +38,9 @@ import android.support.v4.app.NotificationCompat; import android.support.v4.content.LocalBroadcastManager; import android.text.TextUtils; import android.util.Log; - import com.jaredrummler.android.shell.CommandResult; - +import info.pluggabletransports.dispatch.util.TransportListener; +import info.pluggabletransports.dispatch.util.TransportManager; import org.torproject.android.control.ConfigEntry; import org.torproject.android.control.TorControlConnection; import org.torproject.android.service.util.CustomShell; @@ -79,9 +79,6 @@ import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeoutException;
-import info.pluggabletransports.dispatch.util.TransportListener; -import info.pluggabletransports.dispatch.util.TransportManager; - import static org.torproject.android.service.vpn.VpnUtils.getSharedPrefs; import static org.torproject.android.service.vpn.VpnUtils.killProcess;
diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/CustomShell.java b/orbotservice/src/main/java/org/torproject/android/service/util/CustomShell.java index 889e8b4d..db1a08e2 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/CustomShell.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/CustomShell.java @@ -3,17 +3,14 @@ package org.torproject.android.service.util; import android.support.annotation.NonNull; import android.support.annotation.Nullable; import android.support.annotation.WorkerThread; - import com.jaredrummler.android.shell.CommandResult; import com.jaredrummler.android.shell.Shell; import com.jaredrummler.android.shell.ShellExitCode; import com.jaredrummler.android.shell.StreamGobbler;
-import java.io.DataOutputStream; import java.io.IOException; import java.util.ArrayList; import java.util.Collections; -import java.util.Iterator; import java.util.List; import java.util.Map;
diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/CustomTorResourceInstaller.java b/orbotservice/src/main/java/org/torproject/android/service/util/CustomTorResourceInstaller.java index cb4f5c6a..a44ff18d 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/CustomTorResourceInstaller.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/CustomTorResourceInstaller.java @@ -3,7 +3,6 @@ package org.torproject.android.service.util; import android.content.Context; import android.content.pm.ApplicationInfo; import android.util.Log; - import org.torproject.android.binary.TorServiceConstants;
import java.io.File; diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/NativeLoader.java b/orbotservice/src/main/java/org/torproject/android/service/util/NativeLoader.java index 8621add2..e79d4457 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/NativeLoader.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/NativeLoader.java @@ -9,10 +9,8 @@ import java.io.File; import java.io.FileOutputStream; import java.io.InputStream; import java.io.OutputStream; -import java.util.Enumeration; import java.util.zip.ZipEntry; import java.util.zip.ZipFile; -import java.util.zip.ZipInputStream;
public class NativeLoader {
diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/PortForwarder.java b/orbotservice/src/main/java/org/torproject/android/service/util/PortForwarder.java index d487fb43..052aeed0 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/PortForwarder.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/PortForwarder.java @@ -1,7 +1,6 @@ package org.torproject.android.service.util;
import android.util.Log; - import com.offbynull.portmapper.PortMapperFactory; import com.offbynull.portmapper.gateway.Bus; import com.offbynull.portmapper.gateway.Gateway; diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/TCPSourceApp.java b/orbotservice/src/main/java/org/torproject/android/service/util/TCPSourceApp.java index 610e1ab4..2985ae3d 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/TCPSourceApp.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/TCPSourceApp.java @@ -27,6 +27,12 @@ package org.torproject.android.service.util; * */
+import android.annotation.SuppressLint; +import android.content.Context; +import android.content.pm.PackageInfo; +import android.content.pm.PackageManager; +import android.content.pm.PackageManager.NameNotFoundException; + import java.io.BufferedReader; import java.io.File; import java.io.FileNotFoundException; @@ -35,19 +41,12 @@ import java.io.IOException; import java.net.Inet4Address; import java.net.InetAddress; import java.net.NetworkInterface; -import java.net.Socket; import java.net.SocketException; import java.util.Collections; import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern;
-import android.annotation.SuppressLint; -import android.content.Context; -import android.content.pm.PackageInfo; -import android.content.pm.PackageManager; -import android.content.pm.PackageManager.NameNotFoundException; - /** * Main class for the TCPSourceApp library. * @author Sebastiano Gottardo diff --git a/orbotservice/src/main/java/org/torproject/android/service/util/TorServiceUtils.java b/orbotservice/src/main/java/org/torproject/android/service/util/TorServiceUtils.java index 938bb465..e9e88590 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/util/TorServiceUtils.java +++ b/orbotservice/src/main/java/org/torproject/android/service/util/TorServiceUtils.java @@ -4,7 +4,6 @@ package org.torproject.android.service.util;
import android.content.Context; import android.content.SharedPreferences; - import org.torproject.android.service.OrbotConstants; import org.torproject.android.service.TorServiceConstants;
diff --git a/orbotservice/src/main/java/org/torproject/android/service/vpn/OrbotVpnManager.java b/orbotservice/src/main/java/org/torproject/android/service/vpn/OrbotVpnManager.java index 98de7bbb..b78c7a4f 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/vpn/OrbotVpnManager.java +++ b/orbotservice/src/main/java/org/torproject/android/service/vpn/OrbotVpnManager.java @@ -19,10 +19,8 @@ package org.torproject.android.service.vpn; import android.annotation.TargetApi; import android.app.PendingIntent; import android.app.Service; -import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; -import android.content.IntentFilter; import android.content.SharedPreferences; import android.content.pm.PackageManager.NameNotFoundException; import android.net.VpnService; @@ -31,13 +29,10 @@ import android.os.Build; import android.os.Handler; import android.os.Message; import android.os.ParcelFileDescriptor; -import android.support.v4.content.LocalBroadcastManager; import android.util.Log; import android.widget.Toast; - import com.runjva.sourceforge.jsocks.protocol.ProxyServer; import com.runjva.sourceforge.jsocks.server.ServerAuthenticatorNone; - import org.torproject.android.service.OrbotConstants; import org.torproject.android.service.R; import org.torproject.android.service.TorService; diff --git a/orbotservice/src/main/java/org/torproject/android/service/vpn/TorVpnService.java b/orbotservice/src/main/java/org/torproject/android/service/vpn/TorVpnService.java index 78c405f4..ceae17e2 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/vpn/TorVpnService.java +++ b/orbotservice/src/main/java/org/torproject/android/service/vpn/TorVpnService.java @@ -7,7 +7,6 @@ import android.content.Intent; import android.content.IntentFilter; import android.net.VpnService; import android.support.v4.content.LocalBroadcastManager; - import org.torproject.android.service.TorService; import org.torproject.android.service.TorServiceConstants;
diff --git a/orbotservice/src/main/java/org/torproject/android/service/vpn/Tun2Socks.java b/orbotservice/src/main/java/org/torproject/android/service/vpn/Tun2Socks.java index a0ded90e..11c6203e 100644 --- a/orbotservice/src/main/java/org/torproject/android/service/vpn/Tun2Socks.java +++ b/orbotservice/src/main/java/org/torproject/android/service/vpn/Tun2Socks.java @@ -21,12 +21,10 @@ package org.torproject.android.service.vpn;
import android.annotation.TargetApi; import android.content.Context; -import android.content.pm.ApplicationInfo; import android.net.ConnectivityManager; import android.os.Build; import android.os.ParcelFileDescriptor; import android.util.Log; - import org.torproject.android.service.util.TCPSourceApp;
import java.net.DatagramSocket;
tor-commits@lists.torproject.org