Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java

Issue 29379647: Issue 4948 - add possibility to not send data depending on connection properties (Closed)
Patch Set: updated dependency to binaries, updated comment for allowed connection type Created March 30, 2017, 2:12 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « libadblockplus-android/src/org/adblockplus/libadblockplus/IsAllowedConnectionCallback.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java
diff --git a/libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java b/libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java
index 2b6138245dddd39e780ee5c851f7b584956c9681..d91573c863e41378a4cac314b9fb39b9c10a9e3c 100644
--- a/libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java
+++ b/libadblockplus-android/src/org/adblockplus/libadblockplus/android/AdblockEngine.java
@@ -30,6 +30,7 @@ import org.adblockplus.libadblockplus.Filter;
import org.adblockplus.libadblockplus.FilterChangeCallback;
import org.adblockplus.libadblockplus.FilterEngine;
import org.adblockplus.libadblockplus.FilterEngine.ContentType;
+import org.adblockplus.libadblockplus.IsAllowedConnectionCallback;
import org.adblockplus.libadblockplus.JsEngine;
import org.adblockplus.libadblockplus.LogSystem;
import org.adblockplus.libadblockplus.ShowNotificationCallback;
@@ -102,6 +103,7 @@ public final class AdblockEngine
public static AdblockEngine create(final AppInfo appInfo,
final String basePath, boolean enableElemhide,
+ IsAllowedConnectionCallback isAllowedConnectionCallback,
UpdateAvailableCallback updateAvailableCallback,
UpdateCheckDoneCallback updateCheckDoneCallback,
ShowNotificationCallback showNotificationCallback,
@@ -120,7 +122,7 @@ public final class AdblockEngine
engine.webRequest = new AndroidWebRequest(enableElemhide);
engine.jsEngine.setWebRequest(engine.webRequest);
- engine.filterEngine = new FilterEngine(engine.jsEngine);
+ engine.filterEngine = new FilterEngine(engine.jsEngine, isAllowedConnectionCallback);
engine.updateAvailableCallback = updateAvailableCallback;
if (engine.updateAvailableCallback != null)
@@ -148,9 +150,11 @@ public final class AdblockEngine
}
public static AdblockEngine create(final AppInfo appInfo,
- final String basePath, boolean elemhideEnabled)
+ final String basePath,
+ boolean elemhideEnabled,
+ IsAllowedConnectionCallback isAllowedConnectionCallback)
{
- return create(appInfo, basePath, elemhideEnabled, null, null, null, null);
+ return create(appInfo, basePath, elemhideEnabled, isAllowedConnectionCallback, null, null, null, null);
}
public void dispose()
« no previous file with comments | « libadblockplus-android/src/org/adblockplus/libadblockplus/IsAllowedConnectionCallback.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld