You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
902 B
37 lines
902 B
3 years ago
|
import 'package:better_player/better_player.dart';
|
||
|
import 'package:equatable/equatable.dart';
|
||
|
import 'package:teso/Classes/Firebase/Posts.dart';
|
||
|
|
||
|
abstract class VideoPlayerState extends Equatable {
|
||
|
@override
|
||
|
List<Object> get props => const [];
|
||
|
}
|
||
|
|
||
|
class VideoPlayerStateInitial extends VideoPlayerState {
|
||
|
@override
|
||
|
List<Object> get props => const [];
|
||
|
}
|
||
|
|
||
|
class VideoPlayerStateLoading extends VideoPlayerState {}
|
||
|
|
||
|
class VideoPlayerStateError extends VideoPlayerState {
|
||
|
final String message;
|
||
|
|
||
|
VideoPlayerStateError(this.message);
|
||
|
|
||
|
@override
|
||
|
List<Object> get props => [message];
|
||
|
}
|
||
|
|
||
|
class VideoPlayerStateLoaded extends VideoPlayerState {
|
||
|
final FBPosts video;
|
||
|
final BetterPlayerController controller;
|
||
|
|
||
|
VideoPlayerStateLoaded(this.video, this.controller)
|
||
|
: assert(video != null),
|
||
|
assert(controller != null);
|
||
|
|
||
|
@override
|
||
|
List<Object> get props => [video, controller];
|
||
|
}
|