Index: src/org/adblockplus/android/Starter.java |
diff --git a/src/org/adblockplus/android/Starter.java b/src/org/adblockplus/android/Starter.java |
index 42532ad4f7606cca9506f82ecfd3698a0d29603f..fc5859060b47b53a36261e775df25a25a83b47fe 100644 |
--- a/src/org/adblockplus/android/Starter.java |
+++ b/src/org/adblockplus/android/Starter.java |
@@ -27,29 +27,29 @@ public class Starter extends BroadcastReceiver |
{ |
@Override |
- public void onReceive(Context context, Intent intent) |
+ public void onReceive(final Context context, final Intent intent) |
{ |
- String action = intent.getAction(); |
- SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); |
+ final String action = intent.getAction(); |
+ final SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); |
boolean enabled = prefs.getBoolean(context.getString(R.string.pref_enabled), false); |
boolean proxyenabled = prefs.getBoolean(context.getString(R.string.pref_proxyenabled), true); |
- boolean autoconfigured = prefs.getBoolean(context.getString(R.string.pref_proxyautoconfigured), false); |
+ final boolean autoconfigured = prefs.getBoolean(context.getString(R.string.pref_proxyautoconfigured), false); |
if (Intent.ACTION_PACKAGE_REPLACED.equals(action)) |
{ |
- String pkg = context.getApplicationInfo().packageName; |
- boolean us = pkg.equals(intent.getData().getSchemeSpecificPart()); |
+ final String pkg = context.getApplicationInfo().packageName; |
+ final boolean us = pkg.equals(intent.getData().getSchemeSpecificPart()); |
enabled &= us; |
proxyenabled &= us; |
} |
if (Intent.ACTION_BOOT_COMPLETED.equals(action)) |
{ |
- boolean startAtBoot = prefs.getBoolean(context.getString(R.string.pref_startatboot), context.getResources().getBoolean(R.bool.def_startatboot)); |
+ final boolean startAtBoot = prefs.getBoolean(context.getString(R.string.pref_startatboot), context.getResources().getBoolean(R.bool.def_startatboot)); |
enabled &= startAtBoot; |
proxyenabled &= startAtBoot; |
} |
if (enabled) |
{ |
- AdblockPlus application = AdblockPlus.getApplication(); |
+ final AdblockPlus application = AdblockPlus.getApplication(); |
application.setFilteringEnabled(true); |
application.startEngine(); |
} |