From 753437484869ef1dcb6163c9f34a0e5a2847d37a Mon Sep 17 00:00:00 2001 From: R4SAS Date: Mon, 10 Dec 2018 10:02:19 +0300 Subject: [PATCH] remove orbot proxy selection, update about menu --- .../org/purplei2p/lightning/constant/Constants.java | 7 +++---- .../lightning/preference/PreferenceManager.java | 2 -- .../settings/fragment/GeneralSettingsFragment.java | 3 --- .../org/purplei2p/lightning/utils/ProxyUtils.java | 12 ------------ app/src/main/res/values-ru/strings.xml | 8 ++------ app/src/main/res/values/strings.xml | 8 ++------ app/src/main/res/xml/preference_about.xml | 6 +++--- app/src/main/res/xml/preferences_headers.xml | 11 ----------- 8 files changed, 10 insertions(+), 47 deletions(-) diff --git a/app/src/main/java/org/purplei2p/lightning/constant/Constants.java b/app/src/main/java/org/purplei2p/lightning/constant/Constants.java index a98ae38..4241cec 100644 --- a/app/src/main/java/org/purplei2p/lightning/constant/Constants.java +++ b/app/src/main/java/org/purplei2p/lightning/constant/Constants.java @@ -57,14 +57,13 @@ public final class Constants { public static final String FOLDER = "folder://"; // These should match the order of @array/proxy_choices_array - @IntDef({NO_PROXY, PROXY_ORBOT, PROXY_I2P, PROXY_MANUAL}) + @IntDef({NO_PROXY, PROXY_I2P, PROXY_MANUAL}) @Retention(RetentionPolicy.SOURCE) public @interface Proxy {} public static final int NO_PROXY = 0; - public static final int PROXY_ORBOT = 1; - public static final int PROXY_I2P = 2; - public static final int PROXY_MANUAL = 3; + public static final int PROXY_I2P = 1; + public static final int PROXY_MANUAL = 2; // Default text encoding we will use public static final String DEFAULT_ENCODING = "UTF-8"; diff --git a/app/src/main/java/org/purplei2p/lightning/preference/PreferenceManager.java b/app/src/main/java/org/purplei2p/lightning/preference/PreferenceManager.java index e5ebd03..786f076 100644 --- a/app/src/main/java/org/purplei2p/lightning/preference/PreferenceManager.java +++ b/app/src/main/java/org/purplei2p/lightning/preference/PreferenceManager.java @@ -232,7 +232,6 @@ public class PreferenceManager { @Constants.Proxy int proxy = mPrefs.getInt(Name.PROXY_CHOICE, Constants.PROXY_I2P); switch (proxy) { case Constants.NO_PROXY: - case Constants.PROXY_ORBOT: case Constants.PROXY_I2P: case Constants.PROXY_MANUAL: return proxy; @@ -431,7 +430,6 @@ public class PreferenceManager { * Valid choices: * * diff --git a/app/src/main/java/org/purplei2p/lightning/settings/fragment/GeneralSettingsFragment.java b/app/src/main/java/org/purplei2p/lightning/settings/fragment/GeneralSettingsFragment.java index 9cae9be..7c2fad1 100644 --- a/app/src/main/java/org/purplei2p/lightning/settings/fragment/GeneralSettingsFragment.java +++ b/app/src/main/java/org/purplei2p/lightning/settings/fragment/GeneralSettingsFragment.java @@ -194,9 +194,6 @@ public class GeneralSettingsFragment extends LightningPreferenceFragment impleme private void setProxyChoice(@Constants.Proxy int choice) { switch (choice) { - case Constants.PROXY_ORBOT: - choice = ProxyUtils.setProxyChoice(choice, mActivity); - break; case Constants.PROXY_I2P: choice = ProxyUtils.setProxyChoice(choice, mActivity); break; diff --git a/app/src/main/java/org/purplei2p/lightning/utils/ProxyUtils.java b/app/src/main/java/org/purplei2p/lightning/utils/ProxyUtils.java index 6a1cfd8..ccf8cef 100644 --- a/app/src/main/java/org/purplei2p/lightning/utils/ProxyUtils.java +++ b/app/src/main/java/org/purplei2p/lightning/utils/ProxyUtils.java @@ -40,10 +40,6 @@ public class ProxyUtils { case Constants.NO_PROXY: // We shouldn't be here return; - case Constants.PROXY_ORBOT: - host = "localhost"; - port = 8118; - break; case Constants.PROXY_I2P: host = "localhost"; port = 4444; @@ -82,14 +78,6 @@ public class ProxyUtils { @Constants.Proxy public static int setProxyChoice(int choice, @NonNull Activity activity) { - switch (choice) { - case Constants.PROXY_ORBOT: - break; - case Constants.PROXY_I2P: - break; - case Constants.PROXY_MANUAL: - break; - } return choice; } } diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index 693520b..015ac22 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -93,8 +93,8 @@ Карта памяти недоступна Карта памяти подключена к ПК. Для начала загрузки отключите её от ПК, нажав на уведомление. Включить куки в режиме инкогнито - Связаться с разработчиками - twitter.com/RestainoAnthony + Багтрекер + Сообщить о проблеме можно здесь Очистить кэш Кэш очищен Закладки импортированы @@ -126,7 +126,6 @@ HTTP прокси Нет - Orbot I2P Вручную @@ -208,9 +207,6 @@ Удалить все закладки Не удалось открыть файл - FAQ - Часто задаваемые вопросы - Настройки отладки LeakCanary diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 1a1bdb6..436e761 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -93,8 +93,8 @@ USB storage unavailable The storage is busy. To allow downloads, touch \'Turn Off USB Storage\' in the notification. Enable cookies in incognito mode - Contact me - twitter.com/RestainoAnthony + Bugtracker + You can report issues here Clear cache Cache cleared Bookmarks were imported @@ -126,7 +126,6 @@ HTTP proxy None - Orbot I2P Manual @@ -208,9 +207,6 @@ Delete all bookmarks This file doesn\'t exist anymore - FAQ - Frequently asked questions - Debug Settings LeakCanary diff --git a/app/src/main/res/xml/preference_about.xml b/app/src/main/res/xml/preference_about.xml index 9c243d0..9c6dc22 100644 --- a/app/src/main/res/xml/preference_about.xml +++ b/app/src/main/res/xml/preference_about.xml @@ -4,11 +4,11 @@ + android:summary="@string/bugtracker" + android:title="@string/bugtracker_title"> + android:data="https://gitlab.i2pd.xyz/r4sas/lightning-i2p/issues"> diff --git a/app/src/main/res/xml/preferences_headers.xml b/app/src/main/res/xml/preferences_headers.xml index 332cba8..e09bae2 100644 --- a/app/src/main/res/xml/preferences_headers.xml +++ b/app/src/main/res/xml/preferences_headers.xml @@ -19,17 +19,6 @@ android:fragment="org.purplei2p.lightning.settings.fragment.AboutSettingsFragment" android:summary="@string/settings_about_explain" android:title="@string/settings_about"/> -
- - - -