From: Soren Stoutner Date: Sun, 13 Aug 2023 02:06:58 +0000 (-0700) Subject: Increase the delay time that the SSL certificate dialog won't display after restart... X-Git-Tag: v3.16~16 X-Git-Url: https://gitweb.stoutner.com/?a=commitdiff_plain;h=83b0beda5a1374f43e0ea07b7fad4adee9365ea9;p=PrivacyBrowserAndroid.git Increase the delay time that the SSL certificate dialog won't display after restart. https://redmine.stoutner.com/issues/1020 --- diff --git a/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.kt b/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.kt index ac27dcd6..de608492 100644 --- a/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.kt +++ b/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.kt @@ -4223,8 +4223,8 @@ class MainWebViewActivity : AppCompatActivity(), CreateBookmarkDialog.CreateBook // Calculate the milliseconds since the last restart. This can be replaced by the simpler LocalDateTime once the minimum API >= 26. val millisecondsSinceLastRestart = Date().time - restartTime.time - // Only display the SSL certificate dialog if it has been at least 1 second since the last restart as deep restarts sometimes end up selecting a tab twice. - if (millisecondsSinceLastRestart > 1000) { + // Only display the SSL certificate dialog if it has been at least 2 seconds since the last restart as deep restarts sometimes end up selecting a tab twice. + if (millisecondsSinceLastRestart > 2000) { // Instantiate the View SSL Certificate dialog. val viewSslCertificateDialogFragment: DialogFragment = ViewSslCertificateDialog.displayDialog(currentWebView!!.webViewFragmentId, currentWebView!!.getFavoriteIcon())