Improved MacOS support and organized screens and utils

This commit is contained in:
nullpeer
2025-11-30 12:49:33 +03:00
parent ae6fd57040
commit d793498d0a
56 changed files with 255 additions and 63 deletions

View File

@@ -0,0 +1,28 @@
import 'package:shared_preferences/shared_preferences.dart';
class SpoofingService {
static Future<Map<String, dynamic>?> getSpoofedSessionData() async {
final prefs = await SharedPreferences.getInstance();
final isEnabled = prefs.getBool('spoofing_enabled') ?? false;
if (!isEnabled) {
return null; // Если подмена выключена, возвращаем null
}
return {
'user_agent': prefs.getString('spoof_useragent'),
'device_name': prefs.getString('spoof_devicename'),
'os_version': prefs.getString('spoof_osversion'),
'screen': prefs.getString('spoof_screen'),
'timezone': prefs.getString('spoof_timezone'),
'locale': prefs.getString('spoof_locale'),
'device_id': prefs.getString('spoof_deviceid'),
'device_type': prefs.getString('spoof_devicetype'),
'app_version': prefs.getString('spoof_appversion') ?? '25.10.10',
};
}
}