X-Git-Url: https://gitweb.stoutner.com/?p=PrivacyBrowserAndroid.git;a=blobdiff_plain;f=app%2Fsrc%2Fmain%2Fjava%2Fcom%2Fstoutner%2Fprivacybrowser%2Fviews%2FNestedScrollWebView.java;h=5044b27df449d0b498d681e477211042bd142932;hp=44bc9ef105bb20649110ad4866f4cdcaf8f9c799;hb=0cc9b798d6daa99959e33ff94a707516d6db8122;hpb=16ccee9956383ad3a38b09f7a4f7e9aeee92cd42 diff --git a/app/src/main/java/com/stoutner/privacybrowser/views/NestedScrollWebView.java b/app/src/main/java/com/stoutner/privacybrowser/views/NestedScrollWebView.java index 44bc9ef1..5044b27d 100644 --- a/app/src/main/java/com/stoutner/privacybrowser/views/NestedScrollWebView.java +++ b/app/src/main/java/com/stoutner/privacybrowser/views/NestedScrollWebView.java @@ -36,6 +36,10 @@ public class NestedScrollWebView extends WebView implements NestedScrollingChild // The previous Y position needs to be tracked between motion events. private int previousYPosition; + // Track if domain settings are applied to this nested scroll WebView and, if so, the database ID. + private boolean domainSettingsApplied; + private int domainSettingsDatabaseId; + // Basic constructor. public NestedScrollWebView(Context context) { // Roll up to the next constructor. @@ -60,6 +64,26 @@ public class NestedScrollWebView extends WebView implements NestedScrollingChild nestedScrollingChildHelper.setNestedScrollingEnabled(true); } + public void setDomainSettingsApplied(boolean applied) { + // Store the domain settings applied status. + domainSettingsApplied = applied; + } + + public boolean getDomainSettingsApplied() { + // Return the domain settings applied status. + return domainSettingsApplied; + } + + public void setDomainSettingsDatabaseId(int databaseId) { + // Store the domain settings database ID. + domainSettingsDatabaseId = databaseId; + } + + public int getDomainSettingsDatabaseId() { + // Return the domain settings database ID. + return domainSettingsDatabaseId; + } + @Override public boolean onTouchEvent(MotionEvent motionEvent) { // Initialize a tracker to return if this motion event is handled.