From 4293dc176b2352084ef5084a0f90086eb452a253 Mon Sep 17 00:00:00 2001 From: Olexandr Nesterenko Date: Wed, 11 Nov 2015 19:14:39 +0200 Subject: [PATCH 01/20] Add Ukrainian language --- app/src/main/res/values-uk/strings.xml | 44 ++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 app/src/main/res/values-uk/strings.xml diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml new file mode 100644 index 00000000..bed79384 --- /dev/null +++ b/app/src/main/res/values-uk/strings.xml @@ -0,0 +1,44 @@ + +Авторське право \u00A9 2015 M. Bokhorst (M66B) + +Використовуючи NetGuard, ви погоджуєтесь із +GNU General Public License version 3 + + +Було докладено великі зусилля під час розробки та тестування NetGuard, проте, неможливо гарантувати, що воно буде коректно працювати на будь-якому пристрої. NetGuard відомо про збій, під час активації на деяких пристроях. Відомо також, що на деяких пристроях блокується весь трафік. Ці помилки викликані вадами в системі Android, чи програмному забезпеченні від постачальника, тому, будь ласка, не звинувачуйте в цьому NetGuard. \n\nВикористовуючи NetGuard, ви погоджуєтесь із +GNU General Public License version 3 + +Пошук додатку +Налаштування +Запросити +Підтримка +Про +Блокувати типово у Wi-Fi мережі +Блокувати типово у мобільній мережі +Блокувати типово у роумінгу +Керувати системними додатками +Використовувати темну тему +Експорт налаштувань +Імпорт налаштувань +Відкрити налаштування Android VPN + +Визначити правила для системних додатків (для експертів) + +Ви впевнені? +Визначити правила + +NetGuard вимкнено, аби увімкнути, використовуй перемикач, що знаходиться вище + +NetGuard вимкнено +Дію завершено + +NetGuard використовує локальний VPN в якості понори для блокування трафіку. З цієї причини, дозвольте VPN з\'єднання у наступному діалозі + +Спробуйте NetGuard +Дозволити, коли екран увімкнуто +Блокувати у роумінгу +Запуск додатку +Матеріально подякувати +Оцінити +Дякуємо за підтримку! + From c0885a8e9dd070e1500931e483cc45abf395d178 Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 15:43:17 +0100 Subject: [PATCH 02/20] Updated compatibility section --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 1802e32f..7b3fcd83 100644 --- a/README.md +++ b/README.md @@ -68,6 +68,7 @@ Devices / ROMs with a broken VPN implementation: * [Samsung Galaxy A5 / Android 5.02](https://github.com/M66B/NetGuard/issues/20) (all traffic blocked) * Asus ZenFone 2 / Android 5.0.2/5.1.1, reported on XDA (all traffic blocked) +* Lenovo YOGA Tablet Pro-1380L/Yoga Tablet 2 Pro (all traffic blocked) NetGuard will crash when the package *com.android.vpndialogs* has been removed or otherwise is unavailable. From be27d7187d2771aa44741515efe51772706ef69f Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 15:43:44 +0100 Subject: [PATCH 03/20] Donations are voluntary --- app/src/main/res/layout/about.xml | 9 +++++++++ app/src/main/res/values-ar/strings.xml | 1 + app/src/main/res/values-de/strings.xml | 1 + app/src/main/res/values-es/strings.xml | 1 + app/src/main/res/values-fr/strings.xml | 1 + app/src/main/res/values-it/strings.xml | 1 + app/src/main/res/values-ja/strings.xml | 1 + app/src/main/res/values-ko/strings.xml | 1 + app/src/main/res/values-nl/strings.xml | 1 + app/src/main/res/values-pl/strings.xml | 1 + app/src/main/res/values-ro/strings.xml | 1 + app/src/main/res/values-ru/strings.xml | 1 + app/src/main/res/values-sk/strings.xml | 1 + app/src/main/res/values-uk/strings.xml | 1 + app/src/main/res/values-zh-rCN/strings.xml | 1 + app/src/main/res/values/strings.xml | 1 + strings.sh | 6 +++--- 17 files changed, 27 insertions(+), 3 deletions(-) diff --git a/app/src/main/res/layout/about.xml b/app/src/main/res/layout/about.xml index c0f12a11..2031b481 100644 --- a/app/src/main/res/layout/about.xml +++ b/app/src/main/res/layout/about.xml @@ -68,6 +68,15 @@ android:visibility="gone" /> + + Action completed NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Block when roaming diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 0e0429fe..e8eadbfe 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -30,6 +30,7 @@ Das wird von Fehlern in Android oder in Software vom Hersteller verursacht. Bitt Aktion abgeschlossen Netguard verwendet ein lokales VPN als Senkgrube für blockierten Netzwerkverkehr, daher muss im nächsten Dialog die VPN Verbindung bestätigt werden. Probier NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Erlauben wenn Bildschirm an Blockiere bei Roaming diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index 17084281..bef1f622 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -31,6 +31,7 @@ Esto es causado por errores en Android, o por el software proporcionado por el f Acción completada NetGuard utiliza un VPN local como un "sumidero" para conexiones de internet bloqueadas, por esta razón debes permitir la conexión VPN en el siguiente diálogo Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Bloquear cuando se esté en roaming diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index e711b682..97b677b4 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -31,6 +31,7 @@ Ceci est causé par des bugs dans Android, ou dans le logiciel fourni par le con Action completed NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Bloquer si roaming diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index b66d99c6..3e6d7716 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -32,6 +32,7 @@ Ció è causato da alcuni bug contenuti in Android, o in programmi forniti dal p Azione completata NetGuard utilizza una VPN locale come pozzo per bloccare il traffico internet, per questo motivo è necessario abilitare la connessione VPN nella schermata successiva Prova NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Permetti quando lo schermo è acceso Blocca quando in roaming diff --git a/app/src/main/res/values-ja/strings.xml b/app/src/main/res/values-ja/strings.xml index 798be22d..460d96b5 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/app/src/main/res/values-ja/strings.xml @@ -22,6 +22,7 @@ 設定をインポート Android VPN 設定を開く Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. システムアプリケーションのルールを定義します (エキスパート向け) diff --git a/app/src/main/res/values-ko/strings.xml b/app/src/main/res/values-ko/strings.xml index 935e976c..a9c10366 100644 --- a/app/src/main/res/values-ko/strings.xml +++ b/app/src/main/res/values-ko/strings.xml @@ -31,6 +31,7 @@ These issues are caused by bugs in Android, or in the software provided by the m Action completed NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Block when roaming diff --git a/app/src/main/res/values-nl/strings.xml b/app/src/main/res/values-nl/strings.xml index 19a17035..95878b93 100644 --- a/app/src/main/res/values-nl/strings.xml +++ b/app/src/main/res/values-nl/strings.xml @@ -31,6 +31,7 @@ These issues are caused by bugs in Android, or in the software provided by the m Actie uitgevoerd NetGuard gebruikt een lokaal VPN als een sinkhole voor geblokkeerd internetverkeer, om deze reden moet u een VPN-verbinding in de volgende dialoog toestaan. Probeer NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Sta toe als scherm aan is Blokkeer bij roamen diff --git a/app/src/main/res/values-pl/strings.xml b/app/src/main/res/values-pl/strings.xml index f7a63059..09114c05 100644 --- a/app/src/main/res/values-pl/strings.xml +++ b/app/src/main/res/values-pl/strings.xml @@ -31,6 +31,7 @@ Problemy te są spowodowane błędami w samym Androidzie, lub oprogramowaniu dos Wykonano NetGuard używa lokalnego VPNa aby zablokować ruch internetowy. Z tego powodu należy zezwolić na połączenie VPN w następnym kroku. Spróbuj NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Blokuj gdy roaming diff --git a/app/src/main/res/values-ro/strings.xml b/app/src/main/res/values-ro/strings.xml index d25a032e..60198139 100644 --- a/app/src/main/res/values-ro/strings.xml +++ b/app/src/main/res/values-ro/strings.xml @@ -31,6 +31,7 @@ Acest lucru este cauzat de bug-uri in Android sau in software-ul pus la dispozit Setari aplicate NetGuard foloseste o conexiune locala VPN ca o \"gaura neagra\" pentru traficul de internet blocat, din acest motiv la urmatoarea fereastra de dialog trebuie sa acceptati crearea conexiunii VPN. Incearca NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Permite doar cand ecranul este pornit Blocheaza in roaming diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index f1e26168..53d9610e 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -29,6 +29,7 @@ Действие завершено NetGuard использует локальный VPN, чтобы блокировать интернет трафик. По этой причине, пожалуйста, разрешите VPN-подключения в следующем диалоговом окне. Попробуйте новый фаервол NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Разрешить, когда экран включен Блокировать в роуминге diff --git a/app/src/main/res/values-sk/strings.xml b/app/src/main/res/values-sk/strings.xml index eed5f45e..3c38cfe7 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/app/src/main/res/values-sk/strings.xml @@ -31,6 +31,7 @@ Je to spôsobené chybami v Androide alebo v softvéri poskytovanom výrobcom, p Akcia bola dokončená NetGuard používa lokálnu VPN sieť na zablokovanie sieťovej prevádzky, a preto by ste mali povoliť VPN pripojenie v ďalšom okne Skúsiť NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Povoliť pri zapnutej obrazovke Blokovať pri roamingu diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml index bed79384..a5519ff9 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/app/src/main/res/values-uk/strings.xml @@ -35,6 +35,7 @@ NetGuard вимкнено, аби увімкнути, використовуй NetGuard використовує локальний VPN в якості понори для блокування трафіку. З цієї причини, дозвольте VPN з\'єднання у наступному діалозі Спробуйте NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Дозволити, коли екран увімкнуто Блокувати у роумінгу Запуск додатку diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml index 9683b412..5fe1e2e7 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/app/src/main/res/values-zh-rCN/strings.xml @@ -31,6 +31,7 @@ 操作完成 NetGuard使用一个本地VPN服务来重定向被阻挡的网络流量, 因此请在下一个对话框中允许建立VPN连接 试用NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. 亮屏时允许 漫游时阻止 diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 00c8e6b8..7aa5b455 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -32,6 +32,7 @@ These issues are caused by bugs in Android, or in the software provided by the m Action completed NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog Try NetGuard + Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. Allow when screen is on Block when roaming diff --git a/strings.sh b/strings.sh index cf55df56..e062c79c 100644 --- a/strings.sh +++ b/strings.sh @@ -1,6 +1,6 @@ #!/bin/bash -#grep -RIl "\Prevent NetGuard from being uninstalled' +grep -RIl "\Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done.' -grep -RIl "\ Date: Thu, 12 Nov 2015 15:53:01 +0100 Subject: [PATCH 04/20] Updated Play store description --- PLAY-ro.md | 2 +- PLAY-zh-rCN.md | 2 +- PLAY.md | 6 +++++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/PLAY-ro.md b/PLAY-ro.md index 0f3c2ac4..dc95f280 100644 --- a/PLAY-ro.md +++ b/PLAY-ro.md @@ -3,7 +3,7 @@ Play store Title ----- -NetGuard +NetGuard - no-root firewall Short description diff --git a/PLAY-zh-rCN.md b/PLAY-zh-rCN.md index b6a26f6d..30343f91 100644 --- a/PLAY-zh-rCN.md +++ b/PLAY-zh-rCN.md @@ -3,7 +3,7 @@ Play store Title ----- -NetGuard +NetGuard - no-root firewall Short description diff --git a/PLAY.md b/PLAY.md index 972f1905..ba6c4f1d 100644 --- a/PLAY.md +++ b/PLAY.md @@ -3,7 +3,7 @@ Play store Title ----- -NetGuard +NetGuard - no-root firewall Short description @@ -44,6 +44,10 @@ Features: Most of these features are the result of sending selected traffic to a VPN sinkhole, instead of filtering all internet traffic. This means that advanced features, like address-based filtering (needed for hosts blocking), traffic logging, and on-demand configuration, are not possible. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. + For up to date info on device compatibility, questions and answers please read more here: http://forum.xda-developers.com/showthread.php?t=3233012 If you like to test new features, you can participate in the test program: https://play.google.com/apps/testing/eu.faircode.netguard + +The source code is available here: https://github.com/M66B/NetGuard From 89db2ed4f8c9b32d91dde5d302bf75a31e293f47 Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 16:13:03 +0100 Subject: [PATCH 05/20] Fixed switch position after denying VPN connection --- app/src/main/java/eu/faircode/netguard/ActivityMain.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/java/eu/faircode/netguard/ActivityMain.java b/app/src/main/java/eu/faircode/netguard/ActivityMain.java index 55bfd029..00f5918c 100644 --- a/app/src/main/java/eu/faircode/netguard/ActivityMain.java +++ b/app/src/main/java/eu/faircode/netguard/ActivityMain.java @@ -128,6 +128,8 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences swEnabled.setChecked(enabled); swEnabled.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() { public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) { + prefs.edit().putBoolean("enabled", isChecked).apply(); + if (isChecked) { Log.i(TAG, "Switch on"); final Intent prepare = VpnService.prepare(ActivityMain.this); From 47a06bbf50bbd13cc5bf9a4f5068e221ba1294c5 Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 16:13:33 +0100 Subject: [PATCH 06/20] Updated text --- app/src/main/res/values-ar/strings.xml | 4 +++- app/src/main/res/values-de/strings.xml | 4 +++- app/src/main/res/values-es/strings.xml | 4 +++- app/src/main/res/values-fr/strings.xml | 4 +++- app/src/main/res/values-it/strings.xml | 4 +++- app/src/main/res/values-ja/strings.xml | 4 +++- app/src/main/res/values-ko/strings.xml | 4 +++- app/src/main/res/values-nl/strings.xml | 4 +++- app/src/main/res/values-pl/strings.xml | 4 +++- app/src/main/res/values-ro/strings.xml | 4 +++- app/src/main/res/values-ru/strings.xml | 4 +++- app/src/main/res/values-sk/strings.xml | 4 +++- app/src/main/res/values-uk/strings.xml | 4 +++- app/src/main/res/values-zh-rCN/strings.xml | 4 +++- app/src/main/res/values/strings.xml | 4 +++- strings.sh | 9 ++++++--- 16 files changed, 51 insertions(+), 18 deletions(-) diff --git a/app/src/main/res/values-ar/strings.xml b/app/src/main/res/values-ar/strings.xml index 8d9f5d47..cc51d08a 100644 --- a/app/src/main/res/values-ar/strings.xml +++ b/app/src/main/res/values-ar/strings.xml @@ -29,7 +29,9 @@ These issues are caused by bugs in Android, or in the software provided by the m التطبيق غير مُفعّل, قم بتفعيل التطبيق من الخيار أعلاه. NetGuard has been disabled Action completed - NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Try NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index e8eadbfe..0bca2075 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -28,7 +28,9 @@ Das wird von Fehlern in Android oder in Software vom Hersteller verursacht. Bitt NetGuard ist deaktiviert, verwende den Schalter um NetGuard zu aktivieren NetGuard wurde deaktiviert Aktion abgeschlossen - Netguard verwendet ein lokales VPN als Senkgrube für blockierten Netzwerkverkehr, daher muss im nächsten Dialog die VPN Verbindung bestätigt werden. + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Probier NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index bef1f622..ed91141d 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -29,7 +29,9 @@ Esto es causado por errores en Android, o por el software proporcionado por el f NetGuard está deshabilitado, utiliza el interruptor de arriba para habilitar a NetGuard NetGuard ha sido deshabilitado Acción completada - NetGuard utiliza un VPN local como un "sumidero" para conexiones de internet bloqueadas, por esta razón debes permitir la conexión VPN en el siguiente diálogo + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Try NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 97b677b4..40a6446a 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -29,7 +29,9 @@ Ceci est causé par des bugs dans Android, ou dans le logiciel fourni par le con NetGuard est désactivé, utilisez le bouton ci-dessus pour activer NetGuard NetGuard a été désactivé Action completed - NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Try NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index 3e6d7716..84deff27 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -30,7 +30,9 @@ Ció è causato da alcuni bug contenuti in Android, o in programmi forniti dal p NetGuard è disabilitata, usa lo switch per abilitarla nuovamente NetGuard è stata disabilitata Azione completata - NetGuard utilizza una VPN locale come pozzo per bloccare il traffico internet, per questo motivo è necessario abilitare la connessione VPN nella schermata successiva + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Prova NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-ja/strings.xml b/app/src/main/res/values-ja/strings.xml index 460d96b5..ad70f424 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/app/src/main/res/values-ja/strings.xml @@ -31,7 +31,9 @@ NetGuard は無効です。NetGuard を有効にするには上のスイッチを使用してください NetGuard は無効になりました 操作を完了しました - NetGuard は、インターネットのトラフィックをブロックするために、下水口としてローカルの VPN を使用しています。このため、次のダイアログで VPN 接続を許可してください + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Allow when screen is on ローミング時にブロック diff --git a/app/src/main/res/values-ko/strings.xml b/app/src/main/res/values-ko/strings.xml index a9c10366..7f991fd7 100644 --- a/app/src/main/res/values-ko/strings.xml +++ b/app/src/main/res/values-ko/strings.xml @@ -29,7 +29,9 @@ These issues are caused by bugs in Android, or in the software provided by the m 넷가드가 해제되어 있습니다. 상단 스위치를 사용해 넷가드를 활성화하세요. 넷가드가 해제되었습니다 Action completed - NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Try NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-nl/strings.xml b/app/src/main/res/values-nl/strings.xml index 95878b93..1d4879cd 100644 --- a/app/src/main/res/values-nl/strings.xml +++ b/app/src/main/res/values-nl/strings.xml @@ -29,7 +29,9 @@ These issues are caused by bugs in Android, or in the software provided by the m NetGuard staat uit, gebruik de schakelaar boven om NetGuard aan te zetten NetGuard is uitgezet Actie uitgevoerd - NetGuard gebruikt een lokaal VPN als een sinkhole voor geblokkeerd internetverkeer, om deze reden moet u een VPN-verbinding in de volgende dialoog toestaan. + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Probeer NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-pl/strings.xml b/app/src/main/res/values-pl/strings.xml index 09114c05..6c03c040 100644 --- a/app/src/main/res/values-pl/strings.xml +++ b/app/src/main/res/values-pl/strings.xml @@ -29,7 +29,9 @@ Problemy te są spowodowane błędami w samym Androidzie, lub oprogramowaniu dos NetGuard jest wyłączony, użyj przełącznika u góry by go uruchomić NetGuard został wyłączony Wykonano - NetGuard używa lokalnego VPNa aby zablokować ruch internetowy. Z tego powodu należy zezwolić na połączenie VPN w następnym kroku. + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Spróbuj NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-ro/strings.xml b/app/src/main/res/values-ro/strings.xml index 60198139..0318651e 100644 --- a/app/src/main/res/values-ro/strings.xml +++ b/app/src/main/res/values-ro/strings.xml @@ -29,7 +29,9 @@ Acest lucru este cauzat de bug-uri in Android sau in software-ul pus la dispozit NetGuard este momentan dezactivat, foloseste comutatorul de mai sus pentru a il activa NetGuard a fost dezactivat Setari aplicate - NetGuard foloseste o conexiune locala VPN ca o \"gaura neagra\" pentru traficul de internet blocat, din acest motiv la urmatoarea fereastra de dialog trebuie sa acceptati crearea conexiunii VPN. + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Incearca NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index 53d9610e..f46a3558 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -27,7 +27,9 @@ NetGuard отключен, используйте переключатель выше для включения NetGuard был отключен Действие завершено - NetGuard использует локальный VPN, чтобы блокировать интернет трафик. По этой причине, пожалуйста, разрешите VPN-подключения в следующем диалоговом окне. + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Попробуйте новый фаервол NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-sk/strings.xml b/app/src/main/res/values-sk/strings.xml index 3c38cfe7..1286643e 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/app/src/main/res/values-sk/strings.xml @@ -29,7 +29,9 @@ Je to spôsobené chybami v Androide alebo v softvéri poskytovanom výrobcom, p NetGuard je vypnutý, použite prepínač vyššie na zapnutie NetGuard NetGuard je vypnutý Akcia bola dokončená - NetGuard používa lokálnu VPN sieť na zablokovanie sieťovej prevádzky, a preto by ste mali povoliť VPN pripojenie v ďalšom okne + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Skúsiť NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml index a5519ff9..54db6507 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/app/src/main/res/values-uk/strings.xml @@ -31,7 +31,9 @@ NetGuard вимкнено, аби увімкнути, використовуй NetGuard вимкнено Дію завершено - + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. NetGuard використовує локальний VPN в якості понори для блокування трафіку. З цієї причини, дозвольте VPN з\'єднання у наступному діалозі Спробуйте NetGuard diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml index 5fe1e2e7..ce95398a 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/app/src/main/res/values-zh-rCN/strings.xml @@ -29,7 +29,9 @@ NetGuard已被停用, 请使用上方的开关启用NetGuard NetGuard已被停用 操作完成 - NetGuard使用一个本地VPN服务来重定向被阻挡的网络流量, 因此请在下一个对话框中允许建立VPN连接 + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. 试用NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 7aa5b455..65d71d8a 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -30,7 +30,9 @@ These issues are caused by bugs in Android, or in the software provided by the m NetGuard is disabled, use the switch above to enable NetGuard NetGuard has been disabled Action completed - NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog + NetGuard uses a local VPN as a sinkhole to block internet traffic. +For this reason, please allow a VPN connection in the next dialog. +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. Try NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. diff --git a/strings.sh b/strings.sh index e062c79c..259deb9f 100644 --- a/strings.sh +++ b/strings.sh @@ -1,6 +1,9 @@ #!/bin/bash -grep -RIl "\Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done.' -#grep -RIl "\NetGuard uses a local VPN as a sinkhole to block internet traffic.\ +For this reason, please allow a VPN connection in the next dialog.\ +Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere.' + #grep -RIl "\ Date: Thu, 12 Nov 2015 16:16:18 +0100 Subject: [PATCH 07/20] Fixed Ukranian translation --- app/src/main/res/values-uk/strings.xml | 76 ++++++++++++-------------- 1 file changed, 35 insertions(+), 41 deletions(-) diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml index 54db6507..78ecbf23 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/app/src/main/res/values-uk/strings.xml @@ -1,47 +1,41 @@ -Авторське право \u00A9 2015 M. Bokhorst (M66B) - -Використовуючи NetGuard, ви погоджуєтесь із -GNU General Public License version 3 - - -Було докладено великі зусилля під час розробки та тестування NetGuard, проте, неможливо гарантувати, що воно буде коректно працювати на будь-якому пристрої. NetGuard відомо про збій, під час активації на деяких пристроях. Відомо також, що на деяких пристроях блокується весь трафік. Ці помилки викликані вадами в системі Android, чи програмному забезпеченні від постачальника, тому, будь ласка, не звинувачуйте в цьому NetGuard. \n\nВикористовуючи NetGuard, ви погоджуєтесь із -GNU General Public License version 3 - -Пошук додатку -Налаштування -Запросити -Підтримка -Про -Блокувати типово у Wi-Fi мережі -Блокувати типово у мобільній мережі -Блокувати типово у роумінгу -Керувати системними додатками -Використовувати темну тему -Експорт налаштувань -Імпорт налаштувань -Відкрити налаштування Android VPN - -Визначити правила для системних додатків (для експертів) - -Ви впевнені? -Визначити правила - -NetGuard вимкнено, аби увімкнути, використовуй перемикач, що знаходиться вище - -NetGuard вимкнено -Дію завершено + Авторське право \u00A9 2015 M. Bokhorst (M66B) + Використовуючи NetGuard, ви погоджуєтесь із GNU General Public License version 3 + Було докладено великі зусилля під час розробки та тестування NetGuard, проте, неможливо гарантувати, що воно буде коректно працювати на будь-якому пристрої. NetGuard відомо про збій, під час активації на деяких пристроях. Відомо також, що на деяких пристроях блокується весь трафік. Ці помилки викликані вадами в системі Android, чи програмному забезпеченні від постачальника, тому, будь ласка, не звинувачуйте в цьому NetGuard. \n\nВикористовуючи NetGuard, ви погоджуєтесь із GNU General Public License version 3 + + Пошук додатку + Налаштування + Запросити + Підтримка + Про + + Блокувати типово у Wi-Fi мережі + Блокувати типово у мобільній мережі + Блокувати типово у роумінгу + Керувати системними додатками + Використовувати темну тему + Експорт налаштувань + Імпорт налаштувань + Відкрити налаштування Android VPN + + Визначити правила для системних додатків (для експертів) + + Ви впевнені? + Визначити правила + NetGuard вимкнено, аби увімкнути, використовуй перемикач, що знаходиться вище + NetGuard вимкнено + Дію завершено NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog. Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. -NetGuard використовує локальний VPN в якості понори для блокування трафіку. З цієї причини, дозвольте VPN з\'єднання у наступному діалозі - -Спробуйте NetGuard + + Спробуйте NetGuard Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. -Дозволити, коли екран увімкнуто -Блокувати у роумінгу -Запуск додатку -Матеріально подякувати -Оцінити -Дякуємо за підтримку! + + Дозволити, коли екран увімкнуто + Блокувати у роумінгу + Запуск додатку + Матеріально подякувати + Оцінити + Дякуємо за підтримку! From 0905f55dd8c6d9edbdf7cafe325efd7edbbe98e2 Mon Sep 17 00:00:00 2001 From: licaon-kter Date: Thu, 12 Nov 2015 18:39:03 +0200 Subject: [PATCH 08/20] Update Romanian description --- PLAY-ro.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/PLAY-ro.md b/PLAY-ro.md index dc95f280..7463c0d8 100644 --- a/PLAY-ro.md +++ b/PLAY-ro.md @@ -3,7 +3,7 @@ Play store Title ----- -NetGuard - no-root firewall +NetGuard - firewall ce nu necesita access root Short description @@ -44,6 +44,10 @@ Caracteristici: Majoritatea functiilor sunt rezultatul trimiterii traficului selectat intr-o "gaura neagra", in loc sa fie filtrat tot traficul de internet. Acest lucru presupune ca functii avansate, cum ar fi filtrarea adreselor (necesara pentru blocarea unor gazde), urmarirea traficului si detectarea aplicatiilor la acces, nu sunt posibile. +Cum NetGuard efectiv nu are permisiunea de a accesa internetul, esti sigur ca traficul tau de internet nu este redirectionat nicaieri. + Pentru informatii la zi despre compatibilitatea dispozitivelor, intrebari si raspunsuri va rugam sa cititi mai multe aici: http://forum.xda-developers.com/showthread.php?t=3233012 Daca doriti sa testati caracteristile in dezvoltare ale aplicatiei, va puteti alatura programului de testare: https://play.google.com/apps/testing/eu.faircode.netguard + +Codul sursa este disponibil aici: https://github.com/M66B/NetGuard From 4bd672d6021e1fb01e79548488b11a4a1c27e0ba Mon Sep 17 00:00:00 2001 From: licaon-kter Date: Thu, 12 Nov 2015 18:44:52 +0200 Subject: [PATCH 09/20] Add actual links for reports --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 7b3fcd83..85270351 100644 --- a/README.md +++ b/README.md @@ -66,9 +66,9 @@ Compatibility Devices / ROMs with a broken VPN implementation: -* [Samsung Galaxy A5 / Android 5.02](https://github.com/M66B/NetGuard/issues/20) (all traffic blocked) -* Asus ZenFone 2 / Android 5.0.2/5.1.1, reported on XDA (all traffic blocked) -* Lenovo YOGA Tablet Pro-1380L/Yoga Tablet 2 Pro (all traffic blocked) +* Samsung Galaxy A5 / Android 5.0.2, [reported on Github](https://github.com/M66B/NetGuard/issues/20) (all traffic blocked) +* Asus ZenFone 2 / Android 5.0.2/5.1.1, [reported on XDA](http://forum.xda-developers.com/showpost.php?p=63619542&postcount=121) (all traffic blocked) +* Lenovo YOGA Tablet Pro-1380L/Yoga Tablet 2 Pro 5.0.1, [reported on XDA](http://forum.xda-developers.com/showpost.php?p=63784102&postcount=278) (all traffic blocked) NetGuard will crash when the package *com.android.vpndialogs* has been removed or otherwise is unavailable. From cd5ae4dcaa1e560617782a43393fa7d98b7e33da Mon Sep 17 00:00:00 2001 From: licaon-kter Date: Thu, 12 Nov 2015 18:57:20 +0200 Subject: [PATCH 10/20] Updated Romanian translation --- app/src/main/res/values-ro/strings.xml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/src/main/res/values-ro/strings.xml b/app/src/main/res/values-ro/strings.xml index 0318651e..fbab9b9d 100644 --- a/app/src/main/res/values-ro/strings.xml +++ b/app/src/main/res/values-ro/strings.xml @@ -29,12 +29,12 @@ Acest lucru este cauzat de bug-uri in Android sau in software-ul pus la dispozit NetGuard este momentan dezactivat, foloseste comutatorul de mai sus pentru a il activa NetGuard a fost dezactivat Setari aplicate - NetGuard uses a local VPN as a sinkhole to block internet traffic. -For this reason, please allow a VPN connection in the next dialog. -Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. + NetGuard foloseste o conexiune locala VPN ca o \"gaura neagra\" pentru traficul de internet blocat. +Din acest motiv la urmatoarea fereastra de dialog trebuie sa acceptati crearea conexiunii VPN. +Cum NetGuard efectiv nu are permisiunea de a accesa internetul, esti sigur ca traficul tau de internet nu este redirectionat nicaieri. Incearca NetGuard - Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. - + Donatiile sunt voluntare si nu deblocheaza vreo functie ascunsa. Donatiile sunt doar un mod de a iti arata aprecierea pentru munca depusa pentru aceasta aplicatie. + Permite doar cand ecranul este pornit Blocheaza in roaming Porneste aplicatia From 7cd0072c96e67aeecbb85c5d56062b76b424386a Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 18:56:41 +0100 Subject: [PATCH 11/20] Updated Romanian Play store description --- PLAY-ro.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PLAY-ro.md b/PLAY-ro.md index 7463c0d8..72cb6e67 100644 --- a/PLAY-ro.md +++ b/PLAY-ro.md @@ -3,7 +3,7 @@ Play store Title ----- -NetGuard - firewall ce nu necesita access root +NetGuard - firewall fara root Short description From 1c0987bc288efe41398f0232d7c4720b237c4b3b Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 12 Nov 2015 19:03:19 +0100 Subject: [PATCH 12/20] Updated French translation --- app/src/main/res/values-fr/strings.xml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 40a6446a..c0ab4c2a 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -9,7 +9,7 @@ Ceci est causé par des bugs dans Android, ou dans le logiciel fourni par le con Recherche application Paramètres - Invite + Invité Support À propos @@ -22,20 +22,22 @@ Ceci est causé par des bugs dans Android, ou dans le logiciel fourni par le con Importer paramètres Ouvrir les paramètres VPN - Define rules for system applications (for experts) + Definisé les regeles pour les applications du système (Pour experts) Etes-vous sûr ? Enforcing rules NetGuard est désactivé, utilisez le bouton ci-dessus pour activer NetGuard NetGuard a été désactivé - Action completed + Action completé NetGuard uses a local VPN as a sinkhole to block internet traffic. For this reason, please allow a VPN connection in the next dialog. -Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. - Try NetGuard - Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. +Netguard n\'a pas access a internet,vous savez que votre trafic Internet n\'est pas envoyée partout. - Allow when screen is on + Essayer NetGuard + Les dons sont completement a votre volonté et ils ne débloqueront aucune nouvelle fonctionalitée. +Faire un don est une de façon de montrer votre soutiens aux développeur et votre appréciation pour le travail accompli. + + Accepter si l\'ecran est allumé Bloquer si roaming Lancer l\'application Faire un don From e81b81d95bd0c6d1c93a1c2e19ca9803afa1beb1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Cabrera?= Date: Thu, 12 Nov 2015 13:38:10 -0430 Subject: [PATCH 13/20] Updates Spanish translation --- app/src/main/res/values-es/strings.xml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index ed91141d..44352709 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -9,7 +9,7 @@ Esto es causado por errores en Android, o por el software proporcionado por el f Buscar aplicación Configuración - Invite + Invitar Soporte Acerca de @@ -22,23 +22,23 @@ Esto es causado por errores en Android, o por el software proporcionado por el f Importar configuración Abrir configuración VPN de Android - Define rules for system applications (for experts) + Definir reglas para aplicaciones de sistema (para expertos) ¿Estás seguro? - Enforcing rules + Aplicando reglas NetGuard está deshabilitado, utiliza el interruptor de arriba para habilitar a NetGuard NetGuard ha sido deshabilitado Acción completada - NetGuard uses a local VPN as a sinkhole to block internet traffic. -For this reason, please allow a VPN connection in the next dialog. -Since NetGuard has no internet permission, you know your internet traffic is not being sent anywhere. - Try NetGuard - Donations are completely voluntary and do not unlock any feature. Donations are meant as a way to show your appreciation for the work done. + NetGuard utiliza un VPN local como sumidero para bloquear el acceso a internet. +Por esta razón, por favor permite la conexión VPN en el próximo diálogo. +Puesto que NetGuard no tiene permisos de internet, ya sabes que tu tráfico de internet no está siendo enviado a ninguna parte. + Prueba NetGuard + Las donaciones son completamente voluntarias y no desbloquean ninguna funcionalidad. Las donaciones son una forma de mostrar tu apreciación por el trabajo hecho. - Allow when screen is on + Permitir cuando la pantalla esté encendida Bloquear cuando se esté en roaming Iniciar aplicación Donar - Rate + Calificar ¡Gracias por tu donación! From e551837538a4a08efdbdb37aa3c6ede83c91de13 Mon Sep 17 00:00:00 2001 From: M66B Date: Fri, 13 Nov 2015 08:07:15 +0100 Subject: [PATCH 14/20] Consider Ethernet as a local network --- .../java/eu/faircode/netguard/ActivityMain.java | 4 ++-- .../java/eu/faircode/netguard/SinkholeService.java | 13 +++++++------ app/src/main/java/eu/faircode/netguard/Util.java | 6 +++--- 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/app/src/main/java/eu/faircode/netguard/ActivityMain.java b/app/src/main/java/eu/faircode/netguard/ActivityMain.java index 00f5918c..ec0fbd2d 100644 --- a/app/src/main/java/eu/faircode/netguard/ActivityMain.java +++ b/app/src/main/java/eu/faircode/netguard/ActivityMain.java @@ -390,7 +390,7 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences ivNetwork.setVisibility(View.VISIBLE); ivMetered.setVisibility(View.VISIBLE); - if (Util.isWifiActive(context)) + if (Util.isLocalNetwork(context)) ivNetwork.setImageLevel(1); else { if (Util.isRoaming(context)) @@ -398,7 +398,7 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences else ivNetwork.setImageLevel(2); } - ivMetered.setImageLevel(Util.isMetered(context) ? 1 : 0); + ivMetered.setImageLevel(Util.isMeteredNetwork(context) ? 1 : 0); actionView.postInvalidate(); } diff --git a/app/src/main/java/eu/faircode/netguard/SinkholeService.java b/app/src/main/java/eu/faircode/netguard/SinkholeService.java index f34a671e..a315f31f 100644 --- a/app/src/main/java/eu/faircode/netguard/SinkholeService.java +++ b/app/src/main/java/eu/faircode/netguard/SinkholeService.java @@ -141,10 +141,10 @@ public class SinkholeService extends VpnService { Log.i(TAG, "Starting"); // Check state - boolean wifi = Util.isWifiActive(this); - boolean metered = Util.isMetered(this); + boolean local = Util.isLocalNetwork(this); + boolean metered = Util.isMeteredNetwork(this); boolean interactive = Util.isInteractive(this); - Log.i(TAG, "wifi=" + wifi + + Log.i(TAG, "local=" + local + " metered=" + metered + " roaming=" + last_roaming + " interactive=" + interactive); @@ -304,8 +304,9 @@ public class SinkholeService extends VpnService { Log.i(TAG, "New state roaming=" + last_roaming); reload(null, SinkholeService.this); - } else if (networkType == ConnectivityManager.TYPE_WIFI) { - // Wifi connected/disconnected + } else if (networkType == ConnectivityManager.TYPE_WIFI || + networkType == ConnectivityManager.TYPE_ETHERNET) { + // Local network connected/disconnected reload(null, SinkholeService.this); } } @@ -454,7 +455,7 @@ public class SinkholeService extends VpnService { public static void reload(String network, Context context) { SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); if (prefs.getBoolean("enabled", false)) - if (network == null || ("wifi".equals(network) ? !Util.isMetered(context) : Util.isMetered(context))) { + if (network == null || ("wifi".equals(network) ? !Util.isMeteredNetwork(context) : Util.isMeteredNetwork(context))) { getLock(context).acquire(); Intent intent = new Intent(context, SinkholeService.class); intent.putExtra(EXTRA_COMMAND, Command.reload); diff --git a/app/src/main/java/eu/faircode/netguard/Util.java b/app/src/main/java/eu/faircode/netguard/Util.java index 6d0a478f..b9299628 100644 --- a/app/src/main/java/eu/faircode/netguard/Util.java +++ b/app/src/main/java/eu/faircode/netguard/Util.java @@ -60,14 +60,14 @@ public class Util { return tm.isNetworkRoaming(); } - public static boolean isWifiActive(Context context) { + public static boolean isLocalNetwork(Context context) { ConnectivityManager cm = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE); NetworkInfo ni = cm.getActiveNetworkInfo(); - return (ni != null && ni.getType() == ConnectivityManager.TYPE_WIFI); + return (ni != null && (ni.getType() == ConnectivityManager.TYPE_WIFI || ni.getType() == ConnectivityManager.TYPE_ETHERNET)); } - public static boolean isMetered(Context context) { + public static boolean isMeteredNetwork(Context context) { ConnectivityManager cm = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE); return cm.isActiveNetworkMetered(); } From bf170b265d49ca4ab26dcd31364843d5d938d084 Mon Sep 17 00:00:00 2001 From: M66B Date: Fri, 13 Nov 2015 08:07:33 +0100 Subject: [PATCH 15/20] New text, use scroll views for small screens --- app/src/main/res/layout/about.xml | 97 ++++++++++++---------- app/src/main/res/layout/vpn.xml | 29 ++++++- app/src/main/res/values-ar/strings.xml | 1 + app/src/main/res/values-de/strings.xml | 1 + app/src/main/res/values-es/strings.xml | 1 + app/src/main/res/values-fr/strings.xml | 1 + app/src/main/res/values-it/strings.xml | 1 + app/src/main/res/values-ja/strings.xml | 1 + app/src/main/res/values-ko/strings.xml | 1 + app/src/main/res/values-nl/strings.xml | 1 + app/src/main/res/values-pl/strings.xml | 1 + app/src/main/res/values-ro/strings.xml | 1 + app/src/main/res/values-ru/strings.xml | 1 + app/src/main/res/values-sk/strings.xml | 1 + app/src/main/res/values-uk/strings.xml | 1 + app/src/main/res/values-zh-rCN/strings.xml | 1 + app/src/main/res/values/strings.xml | 1 + strings.sh | 8 +- 18 files changed, 97 insertions(+), 52 deletions(-) diff --git a/app/src/main/res/layout/about.xml b/app/src/main/res/layout/about.xml index 2031b481..c6cd47e0 100644 --- a/app/src/main/res/layout/about.xml +++ b/app/src/main/res/layout/about.xml @@ -45,55 +45,66 @@ android:text="@string/app_copyright" android:textAppearance="@android:style/TextAppearance.Material.Small" /> - + android:orientation="vertical"> -