Index: src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java |
diff --git a/src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java b/src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java |
index 71024f4ddeb1386f2fe926cac7d86eb024ebbc21..b14630415139094ccbc11c32b0a5fb44eee1b5d7 100644 |
--- a/src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java |
+++ b/src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java |
@@ -136,6 +136,19 @@ public final class Engine |
return list.size() > 0; |
} |
+ public static boolean hasCompatibleSBrowserInstalled(final Context activityContext) |
+ { |
+ try |
+ { |
+ return activityContext.getPackageManager() |
+ .queryIntentActivities(new Intent(ACTION_OPEN_SETTINGS), 0).size() > 0; |
+ } |
+ catch (final Throwable t) |
+ { |
+ return false; |
+ } |
+ } |
+ |
void requestUpdateBroadcast() |
{ |
this.lock(); |