This repository was archived by the owner on Feb 22, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +13
-7
lines changed Expand file tree Collapse file tree 3 files changed +13
-7
lines changed Original file line number Diff line number Diff line change 1+ ## [ 0.3.5] - 2017-05-8
2+
3+ * Workaround for failing dynamic check in Xcode 7/sdk version 9.
4+
15## [ 0.3.4] - 2017-05-08
26
37* Add test.
Original file line number Diff line number Diff line change @@ -35,16 +35,18 @@ - (BOOL)canLaunchURL:(NSString*)urlString {
3535}
3636
3737- (void )launchURL : (NSString *)urlString result : (FlutterResult)result {
38- NSURL * url = [NSURL URLWithString: urlString];
39- UIApplication* application = [UIApplication sharedApplication ];
40- if ([application respondsToSelector: @selector (openURL:options:completionHandler: )]) {
41- // iOS 10 and above
38+ NSURL * url = [NSURL URLWithString: urlString];
39+ UIApplication* application = [UIApplication sharedApplication ];
40+
41+ // Using ifdef as workaround to support running with Xcode 7.0 and sdk version 9
42+ // where the dynamic check fails.
43+ #if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_10_0
4244 [application openURL: url options: @{} completionHandler: ^(BOOL success) {
4345 [self sendResult: success result: result url: url];
4446 }];
45- } else {
47+ # else
4648 [self sendResult: [application openURL: url] result: result url: url];
47- }
49+ # endif
4850}
4951
5052- (void )sendResult : (BOOL )success result : (FlutterResult)result url : (NSURL *)url {
Original file line number Diff line number Diff line change 11name : url_launcher
22
3- version : 0.3.4
3+ version : 0.3.5
44description : A Flutter plugin for launching a URL
55author : Flutter Team <flutter-dev@googlegroups.com>
66homepage : https://github.com/flutter/plugins
You can’t perform that action at this time.
0 commit comments