ente/lib/events/sync_status_update_event.dart

28 lines
474 B
Dart
Raw Normal View History

2020-11-12 16:32:10 +00:00
import 'package:photos/events/event.dart';
class SyncStatusUpdate extends Event {
final int completed;
final int total;
final bool wasStopped;
2020-11-15 07:19:51 +00:00
final SyncStatus status;
2020-11-16 16:35:16 +00:00
final String reason;
2020-11-15 07:19:51 +00:00
SyncStatusUpdate(
this.status, {
this.completed,
this.total,
this.wasStopped = false,
2020-11-16 16:35:16 +00:00
this.reason = "",
});
}
2020-11-15 07:19:51 +00:00
enum SyncStatus {
applying_local_diff,
applying_remote_diff,
preparing_for_upload,
2020-11-15 07:19:51 +00:00
in_progress,
2020-11-16 16:35:16 +00:00
paused,
2020-11-15 07:19:51 +00:00
completed,
error,
}