5122be4bc1
- Move SpeedUnit enum to config/speed_unit.dart - Move ColorTheme/ColorThemes classes to config/color_themes.dart - Extract ProcessedGpsData model from gps_data_manager to models/ - Create OverlayMessage typed class for overlay IPC (replaces raw Maps) - Create ThemeModel with palette rotation and state management
36 lines
1.1 KiB
Dart
36 lines
1.1 KiB
Dart
class ProcessedGpsData {
|
|
final double speed; // Raw speed in m/s
|
|
final double heading; // Raw heading in degrees
|
|
final String displaySpeed; // Formatted speed text (with -- logic)
|
|
final String displayHeading; // Formatted heading text
|
|
final bool isSpeedValid; // True if from recent GPS
|
|
final bool isHeadingValid; // True if from recent GPS
|
|
|
|
const ProcessedGpsData({
|
|
required this.speed,
|
|
required this.heading,
|
|
required this.displaySpeed,
|
|
required this.displayHeading,
|
|
required this.isSpeedValid,
|
|
required this.isHeadingValid,
|
|
});
|
|
|
|
ProcessedGpsData copyWith({
|
|
double? speed,
|
|
double? heading,
|
|
String? displaySpeed,
|
|
String? displayHeading,
|
|
bool? isSpeedValid,
|
|
bool? isHeadingValid,
|
|
}) {
|
|
return ProcessedGpsData(
|
|
speed: speed ?? this.speed,
|
|
heading: heading ?? this.heading,
|
|
displaySpeed: displaySpeed ?? this.displaySpeed,
|
|
displayHeading: displayHeading ?? this.displayHeading,
|
|
isSpeedValid: isSpeedValid ?? this.isSpeedValid,
|
|
isHeadingValid: isHeadingValid ?? this.isHeadingValid,
|
|
);
|
|
}
|
|
}
|