2023-11-07 16:14:53 +00:00
|
|
|
import 'package:flutter/gestures.dart';
|
|
|
|
|
2023-01-29 16:57:47 +00:00
|
|
|
abstract class CameraContainerEvent {
|
|
|
|
const CameraContainerEvent();
|
|
|
|
}
|
|
|
|
|
2023-02-10 21:49:51 +00:00
|
|
|
class RequestPermissionEvent extends CameraContainerEvent {
|
|
|
|
const RequestPermissionEvent();
|
|
|
|
}
|
|
|
|
|
|
|
|
class OpenAppSettingsEvent extends CameraContainerEvent {
|
|
|
|
const OpenAppSettingsEvent();
|
|
|
|
}
|
|
|
|
|
2023-01-29 16:57:47 +00:00
|
|
|
class InitializeEvent extends CameraContainerEvent {
|
|
|
|
const InitializeEvent();
|
|
|
|
}
|
|
|
|
|
2023-05-19 09:12:10 +00:00
|
|
|
class DeinitializeEvent extends CameraContainerEvent {
|
|
|
|
const DeinitializeEvent();
|
2023-02-10 21:49:51 +00:00
|
|
|
}
|
|
|
|
|
2023-01-29 16:57:47 +00:00
|
|
|
class ZoomChangedEvent extends CameraContainerEvent {
|
|
|
|
final double value;
|
|
|
|
|
|
|
|
const ZoomChangedEvent(this.value);
|
2023-06-20 06:43:49 +00:00
|
|
|
|
|
|
|
@override
|
|
|
|
bool operator ==(Object other) {
|
|
|
|
if (identical(this, other)) return true;
|
|
|
|
if (other.runtimeType != runtimeType) return false;
|
|
|
|
return other is ZoomChangedEvent && other.value == value;
|
|
|
|
}
|
|
|
|
|
|
|
|
@override
|
|
|
|
int get hashCode => Object.hash(value, runtimeType);
|
2023-01-29 16:57:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
class ExposureOffsetChangedEvent extends CameraContainerEvent {
|
|
|
|
final double value;
|
|
|
|
|
|
|
|
const ExposureOffsetChangedEvent(this.value);
|
2023-06-20 06:43:49 +00:00
|
|
|
|
|
|
|
@override
|
|
|
|
bool operator ==(Object other) {
|
|
|
|
if (identical(this, other)) return true;
|
|
|
|
if (other.runtimeType != runtimeType) return false;
|
|
|
|
return other is ExposureOffsetChangedEvent && other.value == value;
|
|
|
|
}
|
|
|
|
|
|
|
|
@override
|
|
|
|
int get hashCode => Object.hash(value, runtimeType);
|
2023-01-29 16:57:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
class ExposureOffsetResetEvent extends CameraContainerEvent {
|
|
|
|
const ExposureOffsetResetEvent();
|
|
|
|
}
|
2023-11-07 16:14:53 +00:00
|
|
|
|
|
|
|
class ExposureSpotChangedEvent extends CameraContainerEvent {
|
2023-11-08 12:18:32 +00:00
|
|
|
final Offset? offset;
|
2023-11-07 16:14:53 +00:00
|
|
|
|
|
|
|
const ExposureSpotChangedEvent(this.offset);
|
|
|
|
|
|
|
|
@override
|
|
|
|
bool operator ==(Object other) {
|
|
|
|
if (identical(this, other)) return true;
|
|
|
|
if (other.runtimeType != runtimeType) return false;
|
|
|
|
return other is ExposureSpotChangedEvent && other.offset == offset;
|
|
|
|
}
|
|
|
|
|
|
|
|
@override
|
|
|
|
int get hashCode => Object.hash(offset, runtimeType);
|
|
|
|
}
|