From c0cf6f04dd384599aba8ccf57d2b144cab6e7568 Mon Sep 17 00:00:00 2001 From: JosJuice Date: Sat, 23 Jul 2022 11:33:03 +0200 Subject: [PATCH] Android: Add "Broadband Adapter (Built In)" to settings This makes the feature added in 01ada3850f available in the Android GUI. --- .../dolphinemu/features/settings/model/StringSetting.java | 4 ++++ .../features/settings/ui/SettingsFragmentPresenter.java | 7 ++++++- Source/Android/app/src/main/res/values/arrays.xml | 2 ++ Source/Android/app/src/main/res/values/strings.xml | 2 ++ 4 files changed, 14 insertions(+), 1 deletion(-) diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.java index 751d18f90f..4c4a74da84 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.java @@ -17,6 +17,10 @@ public enum StringSetting implements AbstractStringSetting MAIN_BBA_MAC(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "BBA_MAC", ""), MAIN_BBA_XLINK_IP(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "BBA_XLINK_IP", ""), + // Schthack PSO Server - https://schtserv.com/ + MAIN_BBA_BUILTIN_DNS(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "BBA_BUILTIN_DNS", + "149.56.167.128"), + MAIN_GFX_BACKEND(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "GFXBackend", NativeLibrary.GetDefaultGraphicsBackendName()), diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/ui/SettingsFragmentPresenter.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/ui/SettingsFragmentPresenter.java index ae45cb96ad..dd3fb15506 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/ui/SettingsFragmentPresenter.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/ui/SettingsFragmentPresenter.java @@ -577,12 +577,17 @@ public final class SettingsFragmentPresenter private void addSerialPortSubSettings(ArrayList sl, int serialPort1Type) { - if (serialPort1Type == 10) // XLink Kai + if (serialPort1Type == 10) // Broadband Adapter (XLink Kai) { sl.add(new HyperLinkHeaderSetting(mContext, R.string.xlink_kai_guide_header, 0)); sl.add(new InputStringSetting(mContext, StringSetting.MAIN_BBA_XLINK_IP, R.string.xlink_kai_bba_ip, R.string.xlink_kai_bba_ip_description)); } + else if (serialPort1Type == 12) // Broadband Adapter (Built In) + { + sl.add(new InputStringSetting(mContext, StringSetting.MAIN_BBA_BUILTIN_DNS, + R.string.bba_builtin_dns, R.string.bba_builtin_dns_description)); + } } private void addGcPadSettings(ArrayList sl) diff --git a/Source/Android/app/src/main/res/values/arrays.xml b/Source/Android/app/src/main/res/values/arrays.xml index ff8050b9cb..edce6273aa 100644 --- a/Source/Android/app/src/main/res/values/arrays.xml +++ b/Source/Android/app/src/main/res/values/arrays.xml @@ -102,11 +102,13 @@ Nothing Dummy Broadband Adapter (XLink Kai) + Broadband Adapter (Built In) 255 0 10 + 12 diff --git a/Source/Android/app/src/main/res/values/strings.xml b/Source/Android/app/src/main/res/values/strings.xml index e7b1318b82..e28cc082c0 100644 --- a/Source/Android/app/src/main/res/values/strings.xml +++ b/Source/Android/app/src/main/res/values/strings.xml @@ -166,6 +166,8 @@ For setup instructions, refer to this page. XLink Kai IP Address/hostname IP address or hostname of device running the XLink Kai client + DNS Server + Use 8.8.8.8 for normal DNS, else enter your custom one Interface