2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-22 18:07:55 +00:00

Remove setting to disable UDP broadcast

This commit is contained in:
Albert Vaca Cintora 2025-04-18 10:30:22 +02:00
parent 1236cbe4e3
commit 05e14bb81c
No known key found for this signature in database
2 changed files with 0 additions and 14 deletions

View File

@ -420,12 +420,6 @@ public class LanLinkProvider extends BaseLinkProvider {
}
private void broadcastUdpIdentityPacket(@Nullable Network network) {
SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(context);
if (!preferences.getBoolean(SettingsFragment.KEY_UDP_BROADCAST_ENABLED, true)) {
Log.i("LanLinkProvider", "UDP broadcast is disabled in settings. Skipping.");
return;
}
ThreadHelper.execute(() -> {
List<DeviceHost> hostList = CustomDevicesActivity
.getCustomDeviceList(context);

View File

@ -64,7 +64,6 @@ class SettingsFragment : PreferenceFragmentCompat() {
persistentNotificationPref(context),
trustedNetworkPref(context),
devicesByIpPref(context),
udpBroadcastPref(context),
bluetoothSupportPref(context),
exportLogsPref(context),
moreSettingsPref(context),
@ -200,12 +199,6 @@ class SettingsFragment : PreferenceFragmentCompat() {
))
}
private fun udpBroadcastPref(context: Context) = SwitchPreference(context).apply {
setDefaultValue(true)
key = KEY_UDP_BROADCAST_ENABLED
setTitle(R.string.enable_udp_broadcast)
}
private fun bluetoothSupportPref(context: Context) = SwitchPreference(context).apply {
setDefaultValue(false)
key = KEY_BLUETOOTH_ENABLED
@ -262,7 +255,6 @@ class SettingsFragment : PreferenceFragmentCompat() {
}
companion object {
const val KEY_UDP_BROADCAST_ENABLED: String = "udp_broadcast_enabled"
const val KEY_BLUETOOTH_ENABLED: String = "bluetooth_enabled"
const val KEY_APP_THEME: String = "theme_pref"
}