Created
April 13, 2020 13:53
-
-
Save actuosus/0491b8219dc787604098fb20dfd7e494 to your computer and use it in GitHub Desktop.
Patch file to compile react-native-image-crop-picker with Xcode 10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m b/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
index 0a9fddb..865854b 100644 | |
--- a/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
+++ b/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
@@ -194,9 +194,11 @@ - (void)setUpToolbarItems | |
// Info label | |
UIColor *labelColor = [UIColor blackColor]; | |
+ #ifdef __IPHONE_13_0 | |
if (@available(iOS 13.0, *)) { | |
labelColor = [UIColor labelColor]; | |
} | |
+ #endif | |
NSDictionary *attributes = @{ NSForegroundColorAttributeName: labelColor }; | |
UIBarButtonItem *infoButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:NULL]; | |
infoButtonItem.enabled = NO; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m b/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
index 0a9fddb..865854b 100644 | |
--- a/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
+++ b/node_modules/react-native-image-crop-picker/ios/QBImagePicker/QBImagePicker/QBAssetsViewController.m | |
@@ -194,9 +194,11 @@ - (void)setUpToolbarItems | |
// Info label | |
UIColor *labelColor = [UIColor blackColor]; | |
+ #ifdef __IPHONE_13_0 | |
if (@available(iOS 13.0, *)) { | |
labelColor = [UIColor labelColor]; | |
} | |
+ #endif | |
NSDictionary *attributes = @{ NSForegroundColorAttributeName: labelColor }; | |
UIBarButtonItem *infoButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:NULL]; | |
infoButtonItem.enabled = NO; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment