Remove and disable elasticity

This commit is contained in:
Anton Tananaev 2025-06-13 14:28:18 -07:00
parent e243aacde7
commit 57a38d964f
2 changed files with 2 additions and 16 deletions

View file

@ -17,7 +17,6 @@ class SettingsScreen extends StatefulWidget {
class _SettingsScreenState extends State<SettingsScreen> {
bool buffering = true;
bool preventSuspend = false;
bool disableElasticity = false;
bool stopDetection = false;
bool advanced = false;
@ -31,7 +30,6 @@ class _SettingsScreenState extends State<SettingsScreen> {
setState(() {
buffering = Preferences.instance.getBool(Preferences.buffer) ?? true;
preventSuspend = Preferences.instance.getBool(Preferences.preventSuspend) ?? false;
disableElasticity = Preferences.instance.getBool(Preferences.disableElasticity) ?? false;
stopDetection = Preferences.instance.getBool(Preferences.stopDetection) ?? true;
});
}
@ -160,16 +158,6 @@ class _SettingsScreenState extends State<SettingsScreen> {
setState(() => buffering = value);
},
),
if (advanced)
SwitchListTile(
title: Text(AppLocalizations.of(context)!.disableElasticityLabel),
value: disableElasticity,
onChanged: (value) async {
await Preferences.instance.setBool(Preferences.disableElasticity, value);
await bg.BackgroundGeolocation.setConfig(Preferences.geolocationConfig());
setState(() => disableElasticity = value);
},
),
if (advanced)
SwitchListTile(
title: Text(AppLocalizations.of(context)!.stopDetectionLabel),