1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2025-01-04 06:20:26 +00:00

Check if safe browsing can be enabled

This commit is contained in:
M66B 2022-02-13 21:55:55 +01:00
parent db553478f4
commit 400c135530
2 changed files with 4 additions and 4 deletions

View file

@ -102,8 +102,8 @@ public class ActivityAMP extends ActivityBase {
settings.setCacheMode(WebSettings.LOAD_CACHE_ELSE_NETWORK);
settings.setMixedContentMode(WebSettings.MIXED_CONTENT_ALWAYS_ALLOW);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O)
settings.setSafeBrowsingEnabled(safe_browsing);
if (WebViewEx.isFeatureSupported(WebViewFeature.SAFE_BROWSING_ENABLE))
WebSettingsCompat.setSafeBrowsingEnabled(settings, safe_browsing);
setDarkMode();

View file

@ -82,8 +82,8 @@ public class FragmentDialogOpenFull extends FragmentDialogBase {
settings.setCacheMode(WebSettings.LOAD_CACHE_ELSE_NETWORK);
settings.setMixedContentMode(WebSettings.MIXED_CONTENT_ALWAYS_ALLOW);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O)
settings.setSafeBrowsingEnabled(safe_browsing);
if (WebViewEx.isFeatureSupported(WebViewFeature.SAFE_BROWSING_ENABLE))
WebSettingsCompat.setSafeBrowsingEnabled(settings, safe_browsing);
boolean dark = (Helper.isDarkTheme(context) && !force_light);
if (WebViewEx.isFeatureSupported(WebViewFeature.FORCE_DARK))