diff --git a/lib/screens/metering/components/camera_container/widget_container_camera.dart b/lib/screens/metering/components/camera_container/widget_container_camera.dart index 8d2885d..260eae4 100644 --- a/lib/screens/metering/components/camera_container/widget_container_camera.dart +++ b/lib/screens/metering/components/camera_container/widget_container_camera.dart @@ -17,7 +17,6 @@ import 'package:lightmeter/screens/metering/components/camera_container/state_co import 'package:lightmeter/screens/metering/components/shared/exposure_pairs_list/widget_list_exposure_pairs.dart'; import 'package:lightmeter/screens/metering/components/shared/metering_top_bar/widget_top_bar_metering.dart'; import 'package:lightmeter/screens/metering/components/shared/readings_container/widget_container_readings.dart'; -import 'package:m3_lightmeter_iap/m3_lightmeter_iap.dart'; import 'package:m3_lightmeter_resources/m3_lightmeter_resources.dart'; class CameraContainer extends StatelessWidget { @@ -52,7 +51,11 @@ class CameraContainer extends StatelessWidget { double topBarOverflow = Dimens.readingContainerSingleValueHeight + // ISO & ND -cameraViewHeight; - if (IAPProducts.isPurchased(context, IAPProductType.equipment)) { + + if (MeteringScreenLayout.featureOf( + context, + MeteringScreenLayoutFeature.equipmentProfiles, + )) { topBarOverflow += Dimens.readingContainerSingleValueHeight; topBarOverflow += Dimens.paddingS; } diff --git a/lib/screens/metering/components/shared/readings_container/widget_container_readings.dart b/lib/screens/metering/components/shared/readings_container/widget_container_readings.dart index 98badc1..1a3911e 100644 --- a/lib/screens/metering/components/shared/readings_container/widget_container_readings.dart +++ b/lib/screens/metering/components/shared/readings_container/widget_container_readings.dart @@ -9,7 +9,6 @@ import 'package:lightmeter/res/dimens.dart'; import 'package:lightmeter/screens/metering/components/shared/readings_container/components/animated_dialog_picker/widget_picker_dialog_animated.dart'; import 'package:lightmeter/screens/metering/components/shared/readings_container/components/reading_value_container/widget_container_reading_value.dart'; import 'package:lightmeter/utils/inherited_generics.dart'; -import 'package:m3_lightmeter_iap/m3_lightmeter_iap.dart'; import 'package:m3_lightmeter_resources/m3_lightmeter_resources.dart'; class ReadingsContainer extends StatelessWidget { @@ -36,12 +35,13 @@ class ReadingsContainer extends StatelessWidget { @override Widget build(BuildContext context) { - final layout = MeteringScreenLayout.of(context); return Column( crossAxisAlignment: CrossAxisAlignment.stretch, children: [ - if (IAPProducts.isPurchased(context, IAPProductType.equipment) && - layout[MeteringScreenLayoutFeature.equipmentProfiles]!) ...[ + if (MeteringScreenLayout.featureOf( + context, + MeteringScreenLayoutFeature.equipmentProfiles, + )) ...[ const _EquipmentProfilePicker(), const _InnerPadding(), ],