From b692dfc0bae740891c806bb2ea1c18041bf6b66f Mon Sep 17 00:00:00 2001 From: Soren Stoutner Date: Mon, 20 May 2019 19:39:31 -0700 Subject: [PATCH] Manually handle changes in screen layout. https://redmine.stoutner.com/issues/447 --- app/src/main/AndroidManifest.xml | 75 +++++++++++-------- .../de/guide_ssl_certificates_dark.html | 2 +- .../de/guide_ssl_certificates_light.html | 2 +- .../assets/de/guide_tracking_ids_dark.html | 6 +- .../assets/de/guide_tracking_ids_light.html | 6 +- .../es/guide_ssl_certificates_dark.html | 2 +- .../es/guide_ssl_certificates_light.html | 2 +- .../assets/es/guide_tracking_ids_dark.html | 6 +- .../assets/es/guide_tracking_ids_light.html | 6 +- .../it/guide_ssl_certificates_dark.html | 2 +- .../it/guide_ssl_certificates_light.html | 2 +- .../assets/it/guide_tracking_ids_dark.html | 6 +- .../assets/it/guide_tracking_ids_light.html | 6 +- .../ru/guide_ssl_certificates_dark.html | 2 +- .../ru/guide_ssl_certificates_light.html | 2 +- .../assets/ru/guide_tracking_ids_dark.html | 6 +- .../assets/ru/guide_tracking_ids_light.html | 6 +- .../tr/guide_ssl_certificates_dark.html | 2 +- .../tr/guide_ssl_certificates_light.html | 2 +- .../assets/tr/guide_tracking_ids_dark.html | 6 +- .../assets/tr/guide_tracking_ids_light.html | 6 +- .../activities/ImportExportActivity.java | 4 +- .../activities/MainWebViewActivity.java | 6 +- .../fragments/SettingsFragment.java | 8 +- 24 files changed, 92 insertions(+), 81 deletions(-) diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 8f306a22..13a58e31 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -86,8 +86,9 @@ - - - @@ -186,86 +191,92 @@ android:name=".activities.DomainsActivity" android:label="@string/domains" android:parentActivityName=".activities.MainWebViewActivity" - android:configChanges="keyboard|keyboardHidden" + android:configChanges="screenLayout|keyboard|keyboardHidden" android:screenOrientation="fullUser" android:windowSoftInputMode="stateAlwaysHidden" android:persistableMode="persistNever" tools:ignore="UnusedAttribute" /> - - - - - - diff --git a/app/src/main/assets/de/guide_ssl_certificates_dark.html b/app/src/main/assets/de/guide_ssl_certificates_dark.html index d4a6ba89..7f1c0761 100644 --- a/app/src/main/assets/de/guide_ssl_certificates_dark.html +++ b/app/src/main/assets/de/guide_ssl_certificates_dark.html @@ -51,6 +51,6 @@

SSL-Zertifikate können in den Domänen-Einstellungen verankert werden. Neben dem Schutz gegen MITM-Attacken kann das Verankern von Zertifikaten auch für selbst-erzeugte Zertifikate genutzt werden (z.B. bei WLAN-Routern oder Access-Points). In diesen Fällen werden die sonst üblichen Fehlermeldungen unterdrückt, wenn die Website des Geräts geladen wird. - Tapping on the active tab displays the current website SSL certificate.

+ Durch Antippen des aktiven Tabs wird das SSL-Zertifikat der aktuell darin angezeigten Webseite angezeigt.

\ No newline at end of file diff --git a/app/src/main/assets/de/guide_ssl_certificates_light.html b/app/src/main/assets/de/guide_ssl_certificates_light.html index 9f8f05bc..620cb164 100644 --- a/app/src/main/assets/de/guide_ssl_certificates_light.html +++ b/app/src/main/assets/de/guide_ssl_certificates_light.html @@ -51,6 +51,6 @@

SSL-Zertifikate können in den Domänen-Einstellungen verankert werden. Neben dem Schutz gegen MITM-Attacken kann das Verankern von Zertifikaten auch für selbst-erzeugte Zertifikate genutzt werden (z.B. bei WLAN-Routern oder Access-Points). In diesen Fällen werden die sonst üblichen Fehlermeldungen unterdrückt, wenn die Website des Geräts geladen wird. - Tapping on the active tab displays the current website SSL certificate.

+ Durch Antippen des aktiven Tabs wird das SSL-Zertifikat der aktuell darin angezeigten Webseite angezeigt.

\ No newline at end of file diff --git a/app/src/main/assets/de/guide_tracking_ids_dark.html b/app/src/main/assets/de/guide_tracking_ids_dark.html index 8c486ed9..8f2e6c09 100644 --- a/app/src/main/assets/de/guide_tracking_ids_dark.html +++ b/app/src/main/assets/de/guide_tracking_ids_dark.html @@ -38,9 +38,9 @@ So ignorieren zum Beispiel mit Yahoo, Google, Microsoft und Facebook so gut wie alle grossen Internet-Anbieter zumindest einige DNT-Header.

-

URL Modification

+

URL-Bereinigung

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser entfernt Tracking-relevante Teile aus URLs, wie z.B. ?utm_ von Google Analytics und + ?fbclick= von Facebook. Die URL-Bereinigung kann in den Einstellungen deaktiviert werden, sollte sie Probleme verursachen.

\ No newline at end of file diff --git a/app/src/main/assets/de/guide_tracking_ids_light.html b/app/src/main/assets/de/guide_tracking_ids_light.html index a2b9e6ef..1cf57698 100644 --- a/app/src/main/assets/de/guide_tracking_ids_light.html +++ b/app/src/main/assets/de/guide_tracking_ids_light.html @@ -38,9 +38,9 @@ So ignorieren zum Beispiel mit Yahoo, Google, Microsoft und Facebook so gut wie alle grossen Internet-Anbieter zumindest einige DNT-Header.

-

URL Modification

+

URL-Bereinigung

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser entfernt Tracking-relevante Teile aus URLs, wie z.B. ?utm_ von Google Analytics und + ?fbclick= von Facebook. Die URL-Bereinigung kann in den Einstellungen deaktiviert werden, sollte sie Probleme verursachen.

\ No newline at end of file diff --git a/app/src/main/assets/es/guide_ssl_certificates_dark.html b/app/src/main/assets/es/guide_ssl_certificates_dark.html index 90db832d..cf7bdbd3 100644 --- a/app/src/main/assets/es/guide_ssl_certificates_dark.html +++ b/app/src/main/assets/es/guide_ssl_certificates_dark.html @@ -51,6 +51,6 @@

Los certificados SSL pueden ser fijados en Configuración de Dominios. Además de proteger contra ataques MITM, fijar un certificado autofirmado para un dispositivo como un router inalámbrico o punto de acceso eliminará el mensaje de error que se presenta normalmente cada vez que se carga su página web. - Tapping on the active tab displays the current website SSL certificate.

+ Al tocar la pestaña activa se muestra el certificado SSL de la página web actual.

\ No newline at end of file diff --git a/app/src/main/assets/es/guide_ssl_certificates_light.html b/app/src/main/assets/es/guide_ssl_certificates_light.html index 259e8a8a..b65280a3 100644 --- a/app/src/main/assets/es/guide_ssl_certificates_light.html +++ b/app/src/main/assets/es/guide_ssl_certificates_light.html @@ -51,6 +51,6 @@

Los certificados SSL pueden ser fijados en Configuración de Dominios. Además de proteger contra ataques MITM, fijar un certificado autofirmado para un dispositivo como un router inalámbrico o punto de acceso eliminará el mensaje de error que se presenta normalmente cada vez que se carga su página web. - Tapping on the active tab displays the current website SSL certificate.

+ Al tocar la pestaña activa se muestra el certificado SSL de la página web actual.

\ No newline at end of file diff --git a/app/src/main/assets/es/guide_tracking_ids_dark.html b/app/src/main/assets/es/guide_tracking_ids_dark.html index 41559b6c..e03279bc 100644 --- a/app/src/main/assets/es/guide_tracking_ids_dark.html +++ b/app/src/main/assets/es/guide_tracking_ids_dark.html @@ -35,9 +35,9 @@ todos ellos ignoran al menos algunos encabezados DNT.

-

URL Modification

+

Modificación de URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Navegador Privado elimina las secciones de ID de seguimiento de las URL, como ?utm_ de Google Analytics y + ?fbclick= de Facebook. La modificación de URL puede desactivarse en la configuración si está causando problemas.

\ No newline at end of file diff --git a/app/src/main/assets/es/guide_tracking_ids_light.html b/app/src/main/assets/es/guide_tracking_ids_light.html index ff08265e..daa1cd7f 100644 --- a/app/src/main/assets/es/guide_tracking_ids_light.html +++ b/app/src/main/assets/es/guide_tracking_ids_light.html @@ -35,9 +35,9 @@ todos ellos ignoran al menos algunos encabezados DNT.

-

URL Modification

+

Modificación de URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Navegador Privado elimina las secciones de ID de seguimiento de las URL, como ?utm_ de Google Analytics y + ?fbclick= de Facebook. La modificación de URL puede desactivarse en la configuración si está causando problemas.

\ No newline at end of file diff --git a/app/src/main/assets/it/guide_ssl_certificates_dark.html b/app/src/main/assets/it/guide_ssl_certificates_dark.html index 3efae613..c668f1ce 100644 --- a/app/src/main/assets/it/guide_ssl_certificates_dark.html +++ b/app/src/main/assets/it/guide_ssl_certificates_dark.html @@ -52,6 +52,6 @@

I certificati SSL possono essere appuntati nelle impostazioni dei domini. Oltre a proteggere dagli attacchi “MITM”, appuntare un certificato auto-firmato per un dispositivo come un router wireless o un access point eliminerà il messaggio di errore che si presenta ogni volta che viene caricato un sito web. - Tapping on the active tab displays the current website SSL certificate.

+ Il tocco della scheda attiva mostra il certificato SSL attuale del sito.

\ No newline at end of file diff --git a/app/src/main/assets/it/guide_ssl_certificates_light.html b/app/src/main/assets/it/guide_ssl_certificates_light.html index 08d19fa4..ce2cbaf4 100644 --- a/app/src/main/assets/it/guide_ssl_certificates_light.html +++ b/app/src/main/assets/it/guide_ssl_certificates_light.html @@ -52,6 +52,6 @@

I certificati SSL possono essere appuntati nelle impostazioni dei domini. Oltre a proteggere dagli attacchi “MITM”, appuntare un certificato auto-firmato per un dispositivo come un router wireless o un access point eliminerà il messaggio di errore che si presenta ogni volta che viene caricato un sito web. - Tapping on the active tab displays the current website SSL certificate.

+ Il tocco della scheda attiva mostra il certificato SSL attuale del sito.

\ No newline at end of file diff --git a/app/src/main/assets/it/guide_tracking_ids_dark.html b/app/src/main/assets/it/guide_tracking_ids_dark.html index abdc6938..96319584 100644 --- a/app/src/main/assets/it/guide_tracking_ids_dark.html +++ b/app/src/main/assets/it/guide_tracking_ids_dark.html @@ -35,9 +35,9 @@ che ignorano tutti almeno alcuni degli header DNT.

-

URL Modification

+

Modifica delle URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser rimuove le sezioni traccianti delle URL, come ad esempio ?utm_ di Google Analytics e + ?fbclick= di Facebook. La modifica delle URL può essere disattivata nelle opzioni nel caso in cui crei problemi.

\ No newline at end of file diff --git a/app/src/main/assets/it/guide_tracking_ids_light.html b/app/src/main/assets/it/guide_tracking_ids_light.html index f076f399..9a3b6cab 100644 --- a/app/src/main/assets/it/guide_tracking_ids_light.html +++ b/app/src/main/assets/it/guide_tracking_ids_light.html @@ -35,9 +35,9 @@ che ignorano tutti almeno alcuni degli header DNT.

-

URL Modification

+

Modifica delle URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser rimuove le sezioni traccianti delle URL, come ad esempio ?utm_ di Google Analytics e + ?fbclick= di Facebook. La modifica delle URL può essere disattivata nelle opzioni nel caso in cui crei problemi.

\ No newline at end of file diff --git a/app/src/main/assets/ru/guide_ssl_certificates_dark.html b/app/src/main/assets/ru/guide_ssl_certificates_dark.html index cee764f7..dd2212e2 100644 --- a/app/src/main/assets/ru/guide_ssl_certificates_dark.html +++ b/app/src/main/assets/ru/guide_ssl_certificates_dark.html @@ -48,6 +48,6 @@

Сертификаты SSL могут быть закреплены в настройках домена. Помимо защиты от атак MITM, закрепление самоподписанного сертификата для устройства, такого как беспроводной маршрутизатор или точка доступа, удалит сообщение об ошибке, которое обычно отображается каждый раз, когда загружается его сайт. - Tapping on the active tab displays the current website SSL certificate.

+ При нажатии на активную вкладку отображается текущий сертификат SSL веб-сайта.

\ No newline at end of file diff --git a/app/src/main/assets/ru/guide_ssl_certificates_light.html b/app/src/main/assets/ru/guide_ssl_certificates_light.html index c21fd524..b3fc3d4c 100644 --- a/app/src/main/assets/ru/guide_ssl_certificates_light.html +++ b/app/src/main/assets/ru/guide_ssl_certificates_light.html @@ -48,6 +48,6 @@

Сертификаты SSL могут быть закреплены в настройках домена. Помимо защиты от атак MITM, закрепление самоподписанного сертификата для устройства, такого как беспроводной маршрутизатор или точка доступа, удалит сообщение об ошибке, которое обычно отображается каждый раз, когда загружается его сайт. - Tapping on the active tab displays the current website SSL certificate.

+ При нажатии на активную вкладку отображается текущий сертификат SSL веб-сайта.

\ No newline at end of file diff --git a/app/src/main/assets/ru/guide_tracking_ids_dark.html b/app/src/main/assets/ru/guide_tracking_ids_dark.html index 8df8540f..4d8abd96 100644 --- a/app/src/main/assets/ru/guide_tracking_ids_dark.html +++ b/app/src/main/assets/ru/guide_tracking_ids_dark.html @@ -33,9 +33,9 @@ Например, Yahoo, Google, Microsoft и Facebook игнорируют, по крайней мере, некоторые заголовки DNT.

-

URL Modification

+

Модификация URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser удаляет идентификаторы отслеживания из URL-адресов, такие как ?utm_ из Google Analytics и + ?fbclick= из Facebook. Модификация URL может быть отключена в настройках, если она вызывает проблемы.

\ No newline at end of file diff --git a/app/src/main/assets/ru/guide_tracking_ids_light.html b/app/src/main/assets/ru/guide_tracking_ids_light.html index 83373a6b..ad4d8b33 100644 --- a/app/src/main/assets/ru/guide_tracking_ids_light.html +++ b/app/src/main/assets/ru/guide_tracking_ids_light.html @@ -33,9 +33,9 @@ Например, Yahoo, Google, Microsoft и Facebook игнорируют, по крайней мере, некоторые заголовки DNT.

-

URL Modification

+

Модификация URL

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser удаляет идентификаторы отслеживания из URL-адресов, такие как ?utm_ из Google Analytics и + ?fbclick= из Facebook. Модификация URL может быть отключена в настройках, если она вызывает проблемы.

\ No newline at end of file diff --git a/app/src/main/assets/tr/guide_ssl_certificates_dark.html b/app/src/main/assets/tr/guide_ssl_certificates_dark.html index 8cc3e1d5..bc9d6f82 100644 --- a/app/src/main/assets/tr/guide_ssl_certificates_dark.html +++ b/app/src/main/assets/tr/guide_ssl_certificates_dark.html @@ -48,6 +48,6 @@

SSL sertifikaları Domain Ayarlarından sabitlenebilir. MITM saldırılarına karşı korumanın yanı sıra, kablosuz bir router veya erişim noktası gibi bir cihaz için kendiliğinden imzalı bir sertifikayı sabitlemek, web sitesinin her yüklenmesinde normal olarak gösterilen hata mesajını kaldıracaktır. - Tapping on the active tab displays the current website SSL certificate.

+ Aktif sekmeye dokunmak, geçerli web sitesinin SSL sertifikasını gösterir.

\ No newline at end of file diff --git a/app/src/main/assets/tr/guide_ssl_certificates_light.html b/app/src/main/assets/tr/guide_ssl_certificates_light.html index c85847e3..100d4dd9 100644 --- a/app/src/main/assets/tr/guide_ssl_certificates_light.html +++ b/app/src/main/assets/tr/guide_ssl_certificates_light.html @@ -48,6 +48,6 @@

SSL sertifikaları Domain Ayarlarından sabitlenebilir. MITM saldırılarına karşı korumanın yanı sıra, kablosuz bir router veya erişim noktası gibi bir cihaz için kendiliğinden imzalı bir sertifikayı sabitlemek, web sitesinin her yüklenmesinde normal olarak gösterilen hata mesajını kaldıracaktır. - Tapping on the active tab displays the current website SSL certificate.

+ Aktif sekmeye dokunmak, geçerli web sitesinin SSL sertifikasını gösterir.

\ No newline at end of file diff --git a/app/src/main/assets/tr/guide_tracking_ids_dark.html b/app/src/main/assets/tr/guide_tracking_ids_dark.html index b67e6677..8b444cde 100644 --- a/app/src/main/assets/tr/guide_tracking_ids_dark.html +++ b/app/src/main/assets/tr/guide_tracking_ids_dark.html @@ -33,9 +33,9 @@ Örneğin, Yahoo, Google, Microsoft ve Facebook, en azından bazı DNT başlıklarını yok sayar.

-

URL Modification

+

URL Modifikasyonu

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser, Google Analytics'ten ?utm_ ve Facebook'tan + ?fbclick= gibi URL'deki takip id kısımlarını kaldırır. URL modifikasyonu, herhangi bir soruna yol açması halinde ayarlardan kapatılabilir.

\ No newline at end of file diff --git a/app/src/main/assets/tr/guide_tracking_ids_light.html b/app/src/main/assets/tr/guide_tracking_ids_light.html index 94abbf45..700db3c1 100644 --- a/app/src/main/assets/tr/guide_tracking_ids_light.html +++ b/app/src/main/assets/tr/guide_tracking_ids_light.html @@ -33,9 +33,9 @@ Örneğin, Yahoo, Google, Microsoft ve Facebook, en azından bazı DNT başlıklarını yok sayar.

-

URL Modification

+

URL Modifikasyonu

-

Privacy Browser removes tracking ID sections of URLs, like ?utm_ from Google Analytics and - ?fbclick= from Facebook. URL modification can be turned off in the settings if it is causing issues.

+

Privacy Browser, Google Analytics'ten ?utm_ ve Facebook'tan + ?fbclick= gibi URL'deki takip id kısımlarını kaldırır. URL modifikasyonu, herhangi bir soruna yol açması halinde ayarlardan kapatılabilir.

\ No newline at end of file diff --git a/app/src/main/java/com/stoutner/privacybrowser/activities/ImportExportActivity.java b/app/src/main/java/com/stoutner/privacybrowser/activities/ImportExportActivity.java index 9b34bf3b..c8ff219b 100644 --- a/app/src/main/java/com/stoutner/privacybrowser/activities/ImportExportActivity.java +++ b/app/src/main/java/com/stoutner/privacybrowser/activities/ImportExportActivity.java @@ -971,8 +971,8 @@ public class ImportExportActivity extends AppCompatActivity implements StoragePe System.exit(0); }; - // Restart Privacy Browser after 100 milliseconds to allow enough time for the preferences to be saved. - restartHandler.postDelayed(restartRunnable, 100); + // Restart Privacy Browser after 150 milliseconds to allow enough time for the preferences to be saved. + restartHandler.postDelayed(restartRunnable, 150); } else if (!(encryptionSpinner.getSelectedItemPosition() == OPENPGP_ENCRYPTION)){ // The import was not successful. // Display a snack bar with the import error. diff --git a/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.java b/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.java index 43a17fa5..fbab8bfb 100644 --- a/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.java +++ b/app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.java @@ -504,7 +504,7 @@ public class MainWebViewActivity extends AppCompatActivity implements CreateBook // Create a handler to select the tab. Handler selectTabHandler = new Handler(); - // Create a runnable select the new tab. + // Create a runnable to select the tab. Runnable selectTabRunnable = () -> { // Get a handle for the tab. TabLayout.Tab tab = tabLayout.getTabAt(position); @@ -516,8 +516,8 @@ public class MainWebViewActivity extends AppCompatActivity implements CreateBook tab.select(); }; - // Select the tab layout after 100 milliseconds, which leaves enough time for a new tab to be created. - selectTabHandler.postDelayed(selectTabRunnable, 100); + // Select the tab layout after 150 milliseconds, which leaves enough time for a new tab to be inflated. + selectTabHandler.postDelayed(selectTabRunnable, 150); } } diff --git a/app/src/main/java/com/stoutner/privacybrowser/fragments/SettingsFragment.java b/app/src/main/java/com/stoutner/privacybrowser/fragments/SettingsFragment.java index 1834ea88..7dab898e 100644 --- a/app/src/main/java/com/stoutner/privacybrowser/fragments/SettingsFragment.java +++ b/app/src/main/java/com/stoutner/privacybrowser/fragments/SettingsFragment.java @@ -1038,8 +1038,8 @@ public class SettingsFragment extends PreferenceFragment { System.exit(0); }; - // Restart the activity after 100 milliseconds, so that the app has enough time to save the change to the preference. - allowScreenshotsRestartHandler.postDelayed(allowScreenshotsRestartRunnable, 100); + // Restart the activity after 150 milliseconds, so that the app has enough time to save the change to the preference. + allowScreenshotsRestartHandler.postDelayed(allowScreenshotsRestartRunnable, 150); break; case "easylist": @@ -1658,8 +1658,8 @@ public class SettingsFragment extends PreferenceFragment { System.exit(0); }; - // Restart the activity after 100 milliseconds, so that the app has enough time to save the change to the preference. - changeThemeRestartHandler.postDelayed(changeThemeRestartRunnable, 100); + // Restart the activity after 150 milliseconds, so that the app has enough time to save the change to the preference. + changeThemeRestartHandler.postDelayed(changeThemeRestartRunnable, 150); break; case "night_mode": -- 2.45.2