Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

[camera] Bump minimum Flutter version and iOS deployment target #4327

Merged
merged 2 commits into from
Sep 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/camera/camera/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.9.3

* Update minimum Flutter SDK to 2.5 and iOS deployment target to 9.0.

## 0.9.2+2

* Ensure that setting the exposure offset returns the new offset value on Android.
Expand Down
6 changes: 4 additions & 2 deletions packages/camera/camera/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ A Flutter plugin for iOS and Android allowing access to the device cameras.

*Note*: This plugin is still under development, and some APIs might not be available yet. We are working on a refactor which can be followed here: [issue](https://github.com/flutter/flutter/issues/31225)

## Features:
## Features

* Display live camera preview in a widget.
* Snapshots can be captured and saved to a file.
Expand All @@ -19,7 +19,9 @@ First, add `camera` as a [dependency in your pubspec.yaml file](https://flutter.

### iOS

iOS 10.0 of higher is needed to use the camera plugin. If compiling for any version lower than 10.0 make sure to check the iOS version before using the camera plugin. For example, using the [device_info_plus](https://pub.dev/packages/device_info_plus) plugin.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I stared at "If compiling for any version lower than 10.0 make sure to check the iOS version before using the camera plugin" for awhile before I understood what it was trying to say.

The camera plugin functionality works on iOS 10.0 or higher. If compiling for any version lower than 10.0,
make sure to programmatically check the version of iOS running on the device before using any camera plugin features.
The [device_info_plus](https://pub.dev/packages/device_info_plus) plugin, for example, can be used to check the iOS version.

Add two rows to the `ios/Runner/Info.plist`:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@
<string>arm64</string>
</array>
<key>MinimumOSVersion</key>
<string>8.0</string>
<string>9.0</string>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was done automatically via flutter/flutter#85174 by just flutter building the example project.

</dict>
</plist>
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same, done automatically via flutter/flutter#85174.

MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -554,7 +554,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down
4 changes: 2 additions & 2 deletions packages/camera/camera/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ description: Demonstrates how to use the camera plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.22.0"
sdk: ">=2.14.0 <3.0.0"
flutter: ">=2.5.0"

dependencies:
camera:
Expand Down
2 changes: 1 addition & 1 deletion packages/camera/camera/ios/camera.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ A Flutter plugin to use the camera from your Flutter app.
s.public_header_files = 'Classes/**/*.h'
s.dependency 'Flutter'

s.platform = :ios, '8.0'
s.platform = :ios, '9.0'
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', 'VALID_ARCHS[sdk=iphonesimulator*]' => 'x86_64' }
end
6 changes: 3 additions & 3 deletions packages/camera/camera/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ description: A Flutter plugin for getting information about and controlling the
and streaming image buffers to dart.
repository: https://github.com/flutter/plugins/tree/master/packages/camera/camera
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+camera%22
version: 0.9.2+2
version: 0.9.3

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=2.0.0"
sdk: ">=2.14.0 <3.0.0"
flutter: ">=2.5.0"

flutter:
plugin:
Expand Down