import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:lightmeter/data/models/exposure_pair.dart'; import 'package:lightmeter/data/models/photography_values/iso_value.dart'; import 'package:lightmeter/data/models/photography_values/nd_value.dart'; import 'package:lightmeter/interactors/metering_interactor.dart'; import 'package:lightmeter/screens/metering/communication/bloc_communication_metering.dart'; import 'bloc_container_camera.dart'; import 'widget_container_camera.dart'; class CameraContainerProvider extends StatelessWidget { final ExposurePair? fastest; final ExposurePair? slowest; final IsoValue iso; final NdValue nd; final ValueChanged onIsoChanged; final ValueChanged onNdChanged; final List exposurePairs; const CameraContainerProvider({ required this.fastest, required this.slowest, required this.iso, required this.nd, required this.onIsoChanged, required this.onNdChanged, required this.exposurePairs, super.key, }); @override Widget build(BuildContext context) { return BlocProvider( create: (context) => CameraContainerBloc( context.read(), context.read(), ), child: CameraContainer( fastest: fastest, slowest: slowest, iso: iso, nd: nd, onIsoChanged: onIsoChanged, onNdChanged: onNdChanged, exposurePairs: exposurePairs, ), ); } }