diff --git a/packages/image_picker/image_picker/CHANGELOG.md b/packages/image_picker/image_picker/CHANGELOG.md
index c891c082d394..f0d3345f395e 100644
--- a/packages/image_picker/image_picker/CHANGELOG.md
+++ b/packages/image_picker/image_picker/CHANGELOG.md
@@ -1,3 +1,7 @@
+## 0.8.6+4
+
+* Updates iOS minimum version in README.
+
## 0.8.6+3
* Updates links for the merge of flutter/plugins into flutter/packages.
diff --git a/packages/image_picker/image_picker/README.md b/packages/image_picker/image_picker/README.md
index 8fff8920054c..6c886f0c6536 100755
--- a/packages/image_picker/image_picker/README.md
+++ b/packages/image_picker/image_picker/README.md
@@ -5,9 +5,9 @@
A Flutter plugin for iOS and Android for picking images from the image library,
and taking new pictures with the camera.
-| | Android | iOS | Web |
-|-------------|---------|--------|----------------------------------|
-| **Support** | SDK 21+ | iOS 9+ | [See `image_picker_for_web `][1] |
+| | Android | iOS | Web |
+|-------------|---------|---------|---------------------------------|
+| **Support** | SDK 21+ | iOS 11+ | [See `image_picker_for_web`][1] |
## Installation
@@ -15,8 +15,6 @@ First, add `image_picker` as a [dependency in your pubspec.yaml file](https://fl
### iOS
-This plugin requires iOS 9.0 or higher.
-
Starting with version **0.8.1** the iOS implementation uses PHPicker to pick (multiple) images on iOS 14 or higher.
As a result of implementing PHPicker it becomes impossible to pick HEIC images on the iOS simulator in iOS 14+. This is a known issue. Please test this on a real device, or test with non-HEIC images until Apple solves this issue. [63426347 - Apple known issue](https://www.google.com/search?q=63426347+apple&sxsrf=ALeKk01YnTMid5S0PYvhL8GbgXJ40ZS[…]t=gws-wiz&ved=0ahUKEwjKh8XH_5HwAhWL_rsIHUmHDN8Q4dUDCA8&uact=5)
diff --git a/packages/image_picker/image_picker/example/ios/Flutter/AppFrameworkInfo.plist b/packages/image_picker/image_picker/example/ios/Flutter/AppFrameworkInfo.plist
index 3a9c234f96d4..9b41e7d87980 100755
--- a/packages/image_picker/image_picker/example/ios/Flutter/AppFrameworkInfo.plist
+++ b/packages/image_picker/image_picker/example/ios/Flutter/AppFrameworkInfo.plist
@@ -25,6 +25,6 @@
arm64
MinimumOSVersion
- 9.0
+ 11.0
diff --git a/packages/image_picker/image_picker/example/ios/Podfile b/packages/image_picker/image_picker/example/ios/Podfile
index f7d6a5e68c3a..d207307f86d7 100644
--- a/packages/image_picker/image_picker/example/ios/Podfile
+++ b/packages/image_picker/image_picker/example/ios/Podfile
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
-# platform :ios, '9.0'
+# platform :ios, '11.0'
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
diff --git a/packages/image_picker/image_picker/example/ios/Runner.xcodeproj/project.pbxproj b/packages/image_picker/image_picker/example/ios/Runner.xcodeproj/project.pbxproj
index 589858f39019..5d4b00b375dc 100644
--- a/packages/image_picker/image_picker/example/ios/Runner.xcodeproj/project.pbxproj
+++ b/packages/image_picker/image_picker/example/ios/Runner.xcodeproj/project.pbxproj
@@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
- objectVersion = 46;
+ objectVersion = 54;
objects = {
/* Begin PBXBuildFile section */
@@ -234,10 +234,12 @@
/* Begin PBXShellScriptBuildPhase section */
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
+ "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}",
);
name = "Thin Binary";
outputPaths = (
@@ -248,6 +250,7 @@
};
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
@@ -361,7 +364,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -411,7 +414,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
diff --git a/packages/image_picker/image_picker/example/ios/Runner/Info.plist b/packages/image_picker/image_picker/example/ios/Runner/Info.plist
index f9c1909383ca..423e21fd1672 100755
--- a/packages/image_picker/image_picker/example/ios/Runner/Info.plist
+++ b/packages/image_picker/image_picker/example/ios/Runner/Info.plist
@@ -55,5 +55,9 @@
UIViewControllerBasedStatusBarAppearance
+ CADisableMinimumFrameDurationOnPhone
+
+ UIApplicationSupportsIndirectInputEvents
+
diff --git a/packages/image_picker/image_picker/pubspec.yaml b/packages/image_picker/image_picker/pubspec.yaml
index dedaf322b849..98328379d8ac 100755
--- a/packages/image_picker/image_picker/pubspec.yaml
+++ b/packages/image_picker/image_picker/pubspec.yaml
@@ -3,7 +3,7 @@ description: Flutter plugin for selecting images from the Android and iOS image
library, and taking new pictures with the camera.
repository: https://github.com/flutter/packages/tree/main/packages/image_picker/image_picker
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+image_picker%22
-version: 0.8.6+3
+version: 0.8.6+4
environment:
sdk: ">=2.14.0 <3.0.0"
diff --git a/packages/image_picker/image_picker_ios/CHANGELOG.md b/packages/image_picker/image_picker_ios/CHANGELOG.md
index 43ce3216c77f..62cd3c0a80b8 100644
--- a/packages/image_picker/image_picker_ios/CHANGELOG.md
+++ b/packages/image_picker/image_picker_ios/CHANGELOG.md
@@ -1,3 +1,7 @@
+## 0.8.7
+
+* Updates minimum Flutter version to 3.3 and iOS 11.
+
## 0.8.6+9
* Updates links for the merge of flutter/plugins into flutter/packages.
diff --git a/packages/image_picker/image_picker_ios/example/ios/Flutter/AppFrameworkInfo.plist b/packages/image_picker/image_picker_ios/example/ios/Flutter/AppFrameworkInfo.plist
index 3a9c234f96d4..9b41e7d87980 100755
--- a/packages/image_picker/image_picker_ios/example/ios/Flutter/AppFrameworkInfo.plist
+++ b/packages/image_picker/image_picker_ios/example/ios/Flutter/AppFrameworkInfo.plist
@@ -25,6 +25,6 @@
arm64
MinimumOSVersion
- 9.0
+ 11.0
diff --git a/packages/image_picker/image_picker_ios/example/ios/Podfile b/packages/image_picker/image_picker_ios/example/ios/Podfile
index 5bc7b7e85717..674ea9b53d89 100644
--- a/packages/image_picker/image_picker_ios/example/ios/Podfile
+++ b/packages/image_picker/image_picker_ios/example/ios/Podfile
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
-# platform :ios, '9.0'
+# platform :ios, '11.0'
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
@@ -31,7 +31,7 @@ target 'Runner' do
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
target 'RunnerTests' do
- platform :ios, '9.0'
+ platform :ios, '11.0'
inherit! :search_paths
# Pods for testing
pod 'OCMock', '~> 3.8.1'
diff --git a/packages/image_picker/image_picker_ios/example/ios/Runner.xcodeproj/project.pbxproj b/packages/image_picker/image_picker_ios/example/ios/Runner.xcodeproj/project.pbxproj
index ddbc856d6aa7..11c32e66da76 100644
--- a/packages/image_picker/image_picker_ios/example/ios/Runner.xcodeproj/project.pbxproj
+++ b/packages/image_picker/image_picker_ios/example/ios/Runner.xcodeproj/project.pbxproj
@@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
- objectVersion = 50;
+ objectVersion = 54;
objects = {
/* Begin PBXBuildFile section */
@@ -442,10 +442,12 @@
/* Begin PBXShellScriptBuildPhase section */
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
+ "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}",
);
name = "Thin Binary";
outputPaths = (
@@ -456,6 +458,7 @@
};
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
buildActionMask = 2147483647;
files = (
);
@@ -618,7 +621,7 @@
CODE_SIGN_STYLE = Automatic;
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = RunnerUITests/Info.plist;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
@@ -641,7 +644,7 @@
CODE_SIGN_STYLE = Automatic;
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = RunnerUITests/Info.plist;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.google.RunnerUITests;
@@ -699,7 +702,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -749,7 +752,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- IPHONEOS_DEPLOYMENT_TARGET = 9.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
diff --git a/packages/image_picker/image_picker_ios/example/ios/Runner/Info.plist b/packages/image_picker/image_picker_ios/example/ios/Runner/Info.plist
index f9c1909383ca..423e21fd1672 100755
--- a/packages/image_picker/image_picker_ios/example/ios/Runner/Info.plist
+++ b/packages/image_picker/image_picker_ios/example/ios/Runner/Info.plist
@@ -55,5 +55,9 @@
UIViewControllerBasedStatusBarAppearance
+ CADisableMinimumFrameDurationOnPhone
+
+ UIApplicationSupportsIndirectInputEvents
+
diff --git a/packages/image_picker/image_picker_ios/example/ios/RunnerTests/ImagePickerPluginTests.m b/packages/image_picker/image_picker_ios/example/ios/RunnerTests/ImagePickerPluginTests.m
index 6df5e166bf6a..ede62336a9c9 100644
--- a/packages/image_picker/image_picker_ios/example/ios/RunnerTests/ImagePickerPluginTests.m
+++ b/packages/image_picker/image_picker_ios/example/ios/RunnerTests/ImagePickerPluginTests.m
@@ -182,7 +182,7 @@ - (void)testPickMultiImageShouldUseUIImagePickerControllerOnPreiOS14 {
[mockUIImagePicker setSourceType:UIImagePickerControllerSourceTypePhotoLibrary]);
}
-- (void)testPickImageWithoutFullMetadata API_AVAILABLE(ios(11)) {
+- (void)testPickImageWithoutFullMetadata {
id mockUIImagePicker = OCMClassMock([UIImagePickerController class]);
id photoLibrary = OCMClassMock([PHPhotoLibrary class]);
@@ -200,7 +200,7 @@ - (void)testPickImageWithoutFullMetadata API_AVAILABLE(ios(11)) {
OCMVerify(times(0), [photoLibrary authorizationStatus]);
}
-- (void)testPickMultiImageWithoutFullMetadata API_AVAILABLE(ios(11)) {
+- (void)testPickMultiImageWithoutFullMetadata {
id mockUIImagePicker = OCMClassMock([UIImagePickerController class]);
id photoLibrary = OCMClassMock([PHPhotoLibrary class]);
diff --git a/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPhotoAssetUtil.m b/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPhotoAssetUtil.m
index fef94ad30bea..bf712cdce39a 100644
--- a/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPhotoAssetUtil.m
+++ b/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPhotoAssetUtil.m
@@ -11,19 +11,7 @@
@implementation FLTImagePickerPhotoAssetUtil
+ (PHAsset *)getAssetFromImagePickerInfo:(NSDictionary *)info {
- if (@available(iOS 11, *)) {
- return [info objectForKey:UIImagePickerControllerPHAsset];
- }
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- NSURL *referenceURL = [info objectForKey:UIImagePickerControllerReferenceURL];
- if (!referenceURL) {
- return nil;
- }
- PHFetchResult *result = [PHAsset fetchAssetsWithALAssetURLs:@[ referenceURL ]
- options:nil];
- return result.firstObject;
-#pragma clang diagnostic pop
+ return info[UIImagePickerControllerPHAsset];
}
+ (PHAsset *)getAssetFromPHPickerResult:(PHPickerResult *)result API_AVAILABLE(ios(14)) {
diff --git a/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPlugin.m b/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPlugin.m
index e910f8fc333b..5aadecdf9482 100644
--- a/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPlugin.m
+++ b/packages/image_picker/image_picker_ios/ios/Classes/FLTImagePickerPlugin.m
@@ -137,15 +137,10 @@ - (void)launchUIImagePickerWithSource:(nonnull FLTSourceSpecification *)source
camera:[self cameraDeviceForSource:source]];
break;
case FLTSourceTypeGallery:
- if (@available(iOS 11, *)) {
- if (context.requestFullMetadata) {
- [self checkPhotoAuthorizationWithImagePicker:imagePickerController];
- } else {
- [self showPhotoLibraryWithImagePicker:imagePickerController];
- }
- } else {
- // Prior to iOS 11, accessing gallery requires authorization
+ if (context.requestFullMetadata) {
[self checkPhotoAuthorizationWithImagePicker:imagePickerController];
+ } else {
+ [self showPhotoLibraryWithImagePicker:imagePickerController];
}
break;
default:
diff --git a/packages/image_picker/image_picker_ios/ios/image_picker_ios.podspec b/packages/image_picker/image_picker_ios/ios/image_picker_ios.podspec
index 05d2d8f2b4ce..04da529b87e3 100644
--- a/packages/image_picker/image_picker_ios/ios/image_picker_ios.podspec
+++ b/packages/image_picker/image_picker_ios/ios/image_picker_ios.podspec
@@ -18,6 +18,6 @@ Downloaded by pub (not CocoaPods).
s.public_header_files = 'Classes/**/*.h'
s.module_map = 'Classes/ImagePickerPlugin.modulemap'
s.dependency 'Flutter'
- s.platform = :ios, '9.0'
- s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'i386' }
+ s.platform = :ios, '11.0'
+ s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES' }
end
diff --git a/packages/image_picker/image_picker_ios/pubspec.yaml b/packages/image_picker/image_picker_ios/pubspec.yaml
index c62d029ddaa8..e0a0bbd98792 100755
--- a/packages/image_picker/image_picker_ios/pubspec.yaml
+++ b/packages/image_picker/image_picker_ios/pubspec.yaml
@@ -2,11 +2,11 @@ name: image_picker_ios
description: iOS implementation of the image_picker plugin.
repository: https://github.com/flutter/packages/tree/main/packages/image_picker/image_picker_ios
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+image_picker%22
-version: 0.8.6+9
+version: 0.8.7
environment:
- sdk: ">=2.14.0 <3.0.0"
- flutter: ">=3.0.0"
+ sdk: ">=2.18.0 <3.0.0"
+ flutter: ">=3.3.0"
flutter:
plugin: