├── .gitignore ├── LICENSE ├── Podfile ├── Podfile.lock ├── Pods ├── Headers │ ├── Private │ │ ├── SDWebImage │ │ │ ├── NSButton+WebCache.h │ │ │ ├── NSData+ImageContentType.h │ │ │ ├── NSImage+WebCache.h │ │ │ ├── SDAnimatedImageRep.h │ │ │ ├── SDImageCache.h │ │ │ ├── SDImageCacheConfig.h │ │ │ ├── SDWebImageCoder.h │ │ │ ├── SDWebImageCoderHelper.h │ │ │ ├── SDWebImageCodersManager.h │ │ │ ├── SDWebImageCompat.h │ │ │ ├── SDWebImageDownloader.h │ │ │ ├── SDWebImageDownloaderOperation.h │ │ │ ├── SDWebImageFrame.h │ │ │ ├── SDWebImageGIFCoder.h │ │ │ ├── SDWebImageImageIOCoder.h │ │ │ ├── SDWebImageManager.h │ │ │ ├── SDWebImageOperation.h │ │ │ ├── SDWebImagePrefetcher.h │ │ │ ├── SDWebImageTransition.h │ │ │ ├── UIButton+WebCache.h │ │ │ ├── UIImage+ForceDecode.h │ │ │ ├── UIImage+GIF.h │ │ │ ├── UIImage+MultiFormat.h │ │ │ ├── UIImageView+HighlightedWebCache.h │ │ │ ├── UIImageView+WebCache.h │ │ │ ├── UIView+WebCache.h │ │ │ └── UIView+WebCacheOperation.h │ │ └── TZImagePickerController │ │ │ ├── NSBundle+TZImagePicker.h │ │ │ ├── TZAssetCell.h │ │ │ ├── TZAssetModel.h │ │ │ ├── TZGifPhotoPreviewController.h │ │ │ ├── TZImageCropManager.h │ │ │ ├── TZImageManager.h │ │ │ ├── TZImagePickerController.h │ │ │ ├── TZImageRequestOperation.h │ │ │ ├── TZLocationManager.h │ │ │ ├── TZPhotoPickerController.h │ │ │ ├── TZPhotoPreviewCell.h │ │ │ ├── TZPhotoPreviewController.h │ │ │ ├── TZProgressView.h │ │ │ ├── TZVideoCropController.h │ │ │ ├── TZVideoEditedPreviewController.h │ │ │ ├── TZVideoPlayerController.h │ │ │ └── UIView+TZLayout.h │ └── Public │ │ ├── SDWebImage │ │ ├── NSButton+WebCache.h │ │ ├── NSData+ImageContentType.h │ │ ├── NSImage+WebCache.h │ │ ├── SDAnimatedImageRep.h │ │ ├── SDImageCache.h │ │ ├── SDImageCacheConfig.h │ │ ├── SDWebImageCoder.h │ │ ├── SDWebImageCoderHelper.h │ │ ├── SDWebImageCodersManager.h │ │ ├── SDWebImageCompat.h │ │ ├── SDWebImageDownloader.h │ │ ├── SDWebImageDownloaderOperation.h │ │ ├── SDWebImageFrame.h │ │ ├── SDWebImageGIFCoder.h │ │ ├── SDWebImageImageIOCoder.h │ │ ├── SDWebImageManager.h │ │ ├── SDWebImageOperation.h │ │ ├── SDWebImagePrefetcher.h │ │ ├── SDWebImageTransition.h │ │ ├── UIButton+WebCache.h │ │ ├── UIImage+ForceDecode.h │ │ ├── UIImage+GIF.h │ │ ├── UIImage+MultiFormat.h │ │ ├── UIImageView+HighlightedWebCache.h │ │ ├── UIImageView+WebCache.h │ │ ├── UIView+WebCache.h │ │ └── UIView+WebCacheOperation.h │ │ └── TZImagePickerController │ │ ├── NSBundle+TZImagePicker.h │ │ ├── TZAssetCell.h │ │ ├── TZAssetModel.h │ │ ├── TZGifPhotoPreviewController.h │ │ ├── TZImageCropManager.h │ │ ├── TZImageManager.h │ │ ├── TZImagePickerController.h │ │ ├── TZImageRequestOperation.h │ │ ├── TZLocationManager.h │ │ ├── TZPhotoPickerController.h │ │ ├── TZPhotoPreviewCell.h │ │ ├── TZPhotoPreviewController.h │ │ ├── TZProgressView.h │ │ ├── TZVideoCropController.h │ │ ├── TZVideoEditedPreviewController.h │ │ ├── TZVideoPlayerController.h │ │ └── UIView+TZLayout.h ├── Local Podspecs │ └── TZImagePickerController.podspec.json ├── Manifest.lock ├── Pods.xcodeproj │ └── project.pbxproj ├── SDWebImage │ ├── LICENSE │ ├── README.md │ └── SDWebImage │ │ ├── NSButton+WebCache.h │ │ ├── NSButton+WebCache.m │ │ ├── NSData+ImageContentType.h │ │ ├── NSData+ImageContentType.m │ │ ├── NSImage+WebCache.h │ │ ├── NSImage+WebCache.m │ │ ├── SDAnimatedImageRep.h │ │ ├── SDAnimatedImageRep.m │ │ ├── SDImageCache.h │ │ ├── SDImageCache.m │ │ ├── SDImageCacheConfig.h │ │ ├── SDImageCacheConfig.m │ │ ├── SDWebImageCoder.h │ │ ├── SDWebImageCoder.m │ │ ├── SDWebImageCoderHelper.h │ │ ├── SDWebImageCoderHelper.m │ │ ├── SDWebImageCodersManager.h │ │ ├── SDWebImageCodersManager.m │ │ ├── SDWebImageCompat.h │ │ ├── SDWebImageCompat.m │ │ ├── SDWebImageDownloader.h │ │ ├── SDWebImageDownloader.m │ │ ├── SDWebImageDownloaderOperation.h │ │ ├── SDWebImageDownloaderOperation.m │ │ ├── SDWebImageFrame.h │ │ ├── SDWebImageFrame.m │ │ ├── SDWebImageGIFCoder.h │ │ ├── SDWebImageGIFCoder.m │ │ ├── SDWebImageImageIOCoder.h │ │ ├── SDWebImageImageIOCoder.m │ │ ├── SDWebImageManager.h │ │ ├── SDWebImageManager.m │ │ ├── SDWebImageOperation.h │ │ ├── SDWebImagePrefetcher.h │ │ ├── SDWebImagePrefetcher.m │ │ ├── SDWebImageTransition.h │ │ ├── SDWebImageTransition.m │ │ ├── UIButton+WebCache.h │ │ ├── UIButton+WebCache.m │ │ ├── UIImage+ForceDecode.h │ │ ├── UIImage+ForceDecode.m │ │ ├── UIImage+GIF.h │ │ ├── UIImage+GIF.m │ │ ├── UIImage+MultiFormat.h │ │ ├── UIImage+MultiFormat.m │ │ ├── UIImageView+HighlightedWebCache.h │ │ ├── UIImageView+HighlightedWebCache.m │ │ ├── UIImageView+WebCache.h │ │ ├── UIImageView+WebCache.m │ │ ├── UIView+WebCache.h │ │ ├── UIView+WebCache.m │ │ ├── UIView+WebCacheOperation.h │ │ └── UIView+WebCacheOperation.m ├── TZImagePickerController │ ├── LICENSE │ ├── README.md │ └── TZImagePickerController │ │ └── TZImagePickerController │ │ ├── NSBundle+TZImagePicker.h │ │ ├── NSBundle+TZImagePicker.m │ │ ├── TZAssetCell.h │ │ ├── TZAssetCell.m │ │ ├── TZAssetModel.h │ │ ├── TZAssetModel.m │ │ ├── TZGifPhotoPreviewController.h │ │ ├── TZGifPhotoPreviewController.m │ │ ├── TZImageCropManager.h │ │ ├── TZImageCropManager.m │ │ ├── TZImageManager.h │ │ ├── TZImageManager.m │ │ ├── TZImagePickerController.bundle │ │ ├── MMVideoPreviewPlay@2x.png │ │ ├── MMVideoPreviewPlayHL@2x.png │ │ ├── VideoSendIcon@2x.png │ │ ├── ar.lproj │ │ │ └── Localizable.strings │ │ ├── bg.lproj │ │ │ └── Localizable.strings │ │ ├── cs-CZ.lproj │ │ │ └── Localizable.strings │ │ ├── de.lproj │ │ │ └── Localizable.strings │ │ ├── el.lproj │ │ │ └── Localizable.strings │ │ ├── en.lproj │ │ │ └── Localizable.strings │ │ ├── es.lproj │ │ │ └── Localizable.strings │ │ ├── fr.lproj │ │ │ └── Localizable.strings │ │ ├── he.lproj │ │ │ └── Localizable.strings │ │ ├── iCloudError@2x.png │ │ ├── it.lproj │ │ │ └── Localizable.strings │ │ ├── ja.lproj │ │ │ └── Localizable.strings │ │ ├── ko-KP.lproj │ │ │ └── Localizable.strings │ │ ├── ko.lproj │ │ │ └── Localizable.strings │ │ ├── navi_back@2x.png │ │ ├── nl.lproj │ │ │ └── Localizable.strings │ │ ├── photo_def_photoPickerVc@2x.png │ │ ├── photo_def_previewVc@2x.png │ │ ├── photo_number_icon@2x.png │ │ ├── photo_original_def@2x.png │ │ ├── photo_original_sel@2x.png │ │ ├── photo_sel_photoPickerVc@2x.png │ │ ├── photo_sel_previewVc@2x.png │ │ ├── pl.lproj │ │ │ └── Localizable.strings │ │ ├── preview_number_icon@2x.png │ │ ├── preview_original_def@2x.png │ │ ├── pt.lproj │ │ │ └── Localizable.strings │ │ ├── ro.lproj │ │ │ └── Localizable.strings │ │ ├── ru.lproj │ │ │ └── Localizable.strings │ │ ├── sk.lproj │ │ │ └── Localizable.strings │ │ ├── sv.lproj │ │ │ └── Localizable.strings │ │ ├── takePicture80@2x.png │ │ ├── takePicture@2x.png │ │ ├── th.lproj │ │ │ └── Localizable.strings │ │ ├── tr.lproj │ │ │ └── Localizable.strings │ │ ├── uk.lproj │ │ │ └── Localizable.strings │ │ ├── vi.lproj │ │ │ └── Localizable.strings │ │ ├── zh-Hans.lproj │ │ │ └── Localizable.strings │ │ └── zh-Hant.lproj │ │ │ └── Localizable.strings │ │ ├── TZImagePickerController.h │ │ ├── TZImagePickerController.m │ │ ├── TZImageRequestOperation.h │ │ ├── TZImageRequestOperation.m │ │ ├── TZLocationManager.h │ │ ├── TZLocationManager.m │ │ ├── TZPhotoPickerController.h │ │ ├── TZPhotoPickerController.m │ │ ├── TZPhotoPreviewCell.h │ │ ├── TZPhotoPreviewCell.m │ │ ├── TZPhotoPreviewController.h │ │ ├── TZPhotoPreviewController.m │ │ ├── TZProgressView.h │ │ ├── TZProgressView.m │ │ ├── TZVideoCropController.h │ │ ├── TZVideoCropController.m │ │ ├── TZVideoEditedPreviewController.h │ │ ├── TZVideoEditedPreviewController.m │ │ ├── TZVideoPlayerController.h │ │ ├── TZVideoPlayerController.m │ │ ├── UIView+TZLayout.h │ │ └── UIView+TZLayout.m └── Target Support Files │ ├── Pods-TZImagePreviewController │ ├── Pods-TZImagePreviewController-acknowledgements.markdown │ ├── Pods-TZImagePreviewController-acknowledgements.plist │ ├── Pods-TZImagePreviewController-dummy.m │ ├── Pods-TZImagePreviewController-frameworks.sh │ ├── Pods-TZImagePreviewController-resources-Debug-input-files.xcfilelist │ ├── Pods-TZImagePreviewController-resources-Debug-output-files.xcfilelist │ ├── Pods-TZImagePreviewController-resources-Release-input-files.xcfilelist │ ├── Pods-TZImagePreviewController-resources-Release-output-files.xcfilelist │ ├── Pods-TZImagePreviewController-resources.sh │ ├── Pods-TZImagePreviewController.debug.xcconfig │ └── Pods-TZImagePreviewController.release.xcconfig │ ├── SDWebImage │ ├── SDWebImage-dummy.m │ ├── SDWebImage-prefix.pch │ └── SDWebImage.xcconfig │ └── TZImagePickerController │ ├── TZImagePickerController-dummy.m │ ├── TZImagePickerController-prefix.pch │ └── TZImagePickerController.xcconfig ├── README.md ├── TZImagePreviewController.podspec ├── TZImagePreviewController.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist └── xcshareddata │ └── xcschemes │ └── TZImagePreviewController.xcscheme ├── TZImagePreviewController.xcworkspace ├── contents.xcworkspacedata └── xcshareddata │ └── IDEWorkspaceChecks.plist └── TZImagePreviewController ├── AppDelegate.h ├── AppDelegate.m ├── Assets.xcassets ├── AlbumAddBtn.imageset │ ├── AlbumAddBtn@2x.png │ └── Contents.json ├── AppIcon.appiconset │ └── Contents.json ├── Contents.json ├── back.imageset │ ├── Contents.json │ └── back@2x.png └── photo_delete.imageset │ ├── Contents.json │ └── photo_delete@2x.png ├── Base.lproj ├── LaunchScreen.storyboard └── Main.storyboard ├── Info.plist ├── Sources └── test_video.mov ├── TZImagePreviewController ├── TZImagePreviewController.h └── TZImagePreviewController.m ├── TZTestCell.h ├── TZTestCell.m ├── ViewController.h ├── ViewController.m └── main.m /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore 4 | 5 | .DS_Store 6 | 7 | ## Build generated 8 | build/ 9 | DerivedData/ 10 | 11 | ## Various settings 12 | *.pbxuser 13 | !default.pbxuser 14 | *.mode1v3 15 | !default.mode1v3 16 | *.mode2v3 17 | !default.mode2v3 18 | *.perspectivev3 19 | !default.perspectivev3 20 | xcuserdata/ 21 | 22 | ## Other 23 | *.moved-aside 24 | *.xccheckout 25 | *.xcscmblueprint 26 | 27 | ## Obj-C/Swift specific 28 | *.hmap 29 | *.ipa 30 | *.dSYM.zip 31 | *.dSYM 32 | 33 | # CocoaPods 34 | # 35 | # We recommend against adding the Pods directory to your .gitignore. However 36 | # you should judge for yourself, the pros and cons are mentioned at: 37 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control 38 | # 39 | # Pods/ 40 | 41 | # Carthage 42 | # 43 | # Add this line if you want to avoid checking in source code from Carthage dependencies. 44 | # Carthage/Checkouts 45 | 46 | Carthage/Build 47 | 48 | # fastlane 49 | # 50 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 51 | # screenshots whenever they are needed. 52 | # For more information about the recommended setup visit: 53 | # https://docs.fastlane.tools/best-practices/source-control/#source-control 54 | 55 | fastlane/report.xml 56 | fastlane/Preview.html 57 | fastlane/screenshots/**/*.png 58 | fastlane/test_output 59 | 60 | # Code Injection 61 | # 62 | # After new code Injection tools there's a generated folder /iOSInjectionProject 63 | # https://github.com/johnno1962/injectionforxcode 64 | 65 | iOSInjectionProject/ 66 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 谭真 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Podfile: -------------------------------------------------------------------------------- 1 | platform:ios,"8.0" 2 | 3 | inhibit_all_warnings! 4 | 5 | target 'TZImagePreviewController' do 6 | pod 'TZImagePickerController', '3.6.8' 7 | #pod 'TZImagePickerController', :path => "/Users/tanzhen/Desktop/github/TZImagePickerController" 8 | pod 'SDWebImage', '4.4.3' 9 | end 10 | -------------------------------------------------------------------------------- /Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - SDWebImage (4.4.3): 3 | - SDWebImage/Core (= 4.4.3) 4 | - SDWebImage/Core (4.4.3) 5 | - TZImagePickerController (3.6.8) 6 | 7 | DEPENDENCIES: 8 | - SDWebImage (= 4.4.3) 9 | - TZImagePickerController (= 3.6.8) 10 | 11 | SPEC REPOS: 12 | https://github.com/cocoapods/specs.git: 13 | - SDWebImage 14 | - TZImagePickerController 15 | 16 | SPEC CHECKSUMS: 17 | SDWebImage: c5594f1a19c48d526d321e548902b56b479cd508 18 | TZImagePickerController: 9c249613a73ee88fa352d3f9e77a84e1d820993f 19 | 20 | PODFILE CHECKSUM: 0a0601b043c19f397c913319d0c2d710399d8a21 21 | 22 | COCOAPODS: 1.7.5 23 | -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/NSButton+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSButton+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/NSData+ImageContentType.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSData+ImageContentType.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/NSImage+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSImage+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDAnimatedImageRep.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDAnimatedImageRep.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDImageCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDImageCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDImageCacheConfig.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDImageCacheConfig.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageCoderHelper.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCoderHelper.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageCodersManager.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCodersManager.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageCompat.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCompat.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageDownloader.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageDownloader.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageDownloaderOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageDownloaderOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageFrame.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageFrame.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageGIFCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageGIFCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageImageIOCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageImageIOCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageManager.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageManager.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImagePrefetcher.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImagePrefetcher.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/SDWebImageTransition.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageTransition.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIButton+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIButton+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIImage+ForceDecode.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+ForceDecode.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIImage+GIF.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+GIF.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIImage+MultiFormat.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+MultiFormat.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIImageView+HighlightedWebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImageView+HighlightedWebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIImageView+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImageView+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIView+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIView+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Private/SDWebImage/UIView+WebCacheOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIView+WebCacheOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/NSBundle+TZImagePicker.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/NSBundle+TZImagePicker.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZAssetCell.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetCell.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZAssetModel.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetModel.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZGifPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZGifPhotoPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZImageCropManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageCropManager.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZImageManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageManager.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZImagePickerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZImageRequestOperation.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageRequestOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZLocationManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZLocationManager.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZPhotoPickerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPickerController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZPhotoPreviewCell.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewCell.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZProgressView.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZProgressView.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZVideoCropController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoCropController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZVideoEditedPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoEditedPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/TZVideoPlayerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoPlayerController.h -------------------------------------------------------------------------------- /Pods/Headers/Private/TZImagePickerController/UIView+TZLayout.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/UIView+TZLayout.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/NSButton+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSButton+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/NSData+ImageContentType.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSData+ImageContentType.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/NSImage+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/NSImage+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDAnimatedImageRep.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDAnimatedImageRep.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDImageCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDImageCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDImageCacheConfig.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDImageCacheConfig.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageCoderHelper.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCoderHelper.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageCodersManager.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCodersManager.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageCompat.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageCompat.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageDownloader.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageDownloader.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageDownloaderOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageDownloaderOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageFrame.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageFrame.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageGIFCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageGIFCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageImageIOCoder.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageImageIOCoder.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageManager.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageManager.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImagePrefetcher.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImagePrefetcher.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/SDWebImageTransition.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/SDWebImageTransition.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIButton+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIButton+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIImage+ForceDecode.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+ForceDecode.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIImage+GIF.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+GIF.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIImage+MultiFormat.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImage+MultiFormat.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIImageView+HighlightedWebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImageView+HighlightedWebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIImageView+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIImageView+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIView+WebCache.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIView+WebCache.h -------------------------------------------------------------------------------- /Pods/Headers/Public/SDWebImage/UIView+WebCacheOperation.h: -------------------------------------------------------------------------------- 1 | ../../../SDWebImage/SDWebImage/UIView+WebCacheOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/NSBundle+TZImagePicker.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/NSBundle+TZImagePicker.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZAssetCell.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetCell.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZAssetModel.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetModel.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZGifPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZGifPhotoPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZImageCropManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageCropManager.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZImageManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageManager.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZImagePickerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZImageRequestOperation.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageRequestOperation.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZLocationManager.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZLocationManager.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZPhotoPickerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPickerController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZPhotoPreviewCell.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewCell.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZProgressView.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZProgressView.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZVideoCropController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoCropController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZVideoEditedPreviewController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoEditedPreviewController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/TZVideoPlayerController.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoPlayerController.h -------------------------------------------------------------------------------- /Pods/Headers/Public/TZImagePickerController/UIView+TZLayout.h: -------------------------------------------------------------------------------- 1 | ../../../TZImagePickerController/TZImagePickerController/TZImagePickerController/UIView+TZLayout.h -------------------------------------------------------------------------------- /Pods/Local Podspecs/TZImagePickerController.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "TZImagePickerController", 3 | "version": "3.1.6", 4 | "summary": "A clone of UIImagePickerController, support picking multiple photos、original photo and video", 5 | "homepage": "https://github.com/banchichen/TZImagePickerController", 6 | "license": "MIT", 7 | "authors": { 8 | "banchichen": "tanzhenios@foxmail.com" 9 | }, 10 | "platforms": { 11 | "ios": "8.0" 12 | }, 13 | "source": { 14 | "git": "https://github.com/banchichen/TZImagePickerController.git", 15 | "tag": "3.1.6" 16 | }, 17 | "requires_arc": true, 18 | "resources": "TZImagePickerController/TZImagePickerController/*.{png,bundle}", 19 | "source_files": "TZImagePickerController/TZImagePickerController/*.{h,m}", 20 | "frameworks": "Photos" 21 | } 22 | -------------------------------------------------------------------------------- /Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - SDWebImage (4.4.3): 3 | - SDWebImage/Core (= 4.4.3) 4 | - SDWebImage/Core (4.4.3) 5 | - TZImagePickerController (3.6.8) 6 | 7 | DEPENDENCIES: 8 | - SDWebImage (= 4.4.3) 9 | - TZImagePickerController (= 3.6.8) 10 | 11 | SPEC REPOS: 12 | https://github.com/cocoapods/specs.git: 13 | - SDWebImage 14 | - TZImagePickerController 15 | 16 | SPEC CHECKSUMS: 17 | SDWebImage: c5594f1a19c48d526d321e548902b56b479cd508 18 | TZImagePickerController: 9c249613a73ee88fa352d3f9e77a84e1d820993f 19 | 20 | PODFILE CHECKSUM: 0a0601b043c19f397c913319d0c2d710399d8a21 21 | 22 | COCOAPODS: 1.7.5 23 | -------------------------------------------------------------------------------- /Pods/SDWebImage/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2009-2017 Olivier Poitrey rs@dailymotion.com 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is furnished 8 | to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in all 11 | copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | 21 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/NSData+ImageContentType.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * (c) Fabrice Aneche 5 | * 6 | * For the full copyright and license information, please view the LICENSE 7 | * file that was distributed with this source code. 8 | */ 9 | 10 | #import 11 | #import "SDWebImageCompat.h" 12 | 13 | typedef NS_ENUM(NSInteger, SDImageFormat) { 14 | SDImageFormatUndefined = -1, 15 | SDImageFormatJPEG = 0, 16 | SDImageFormatPNG, 17 | SDImageFormatGIF, 18 | SDImageFormatTIFF, 19 | SDImageFormatWebP, 20 | SDImageFormatHEIC, 21 | SDImageFormatHEIF 22 | }; 23 | 24 | @interface NSData (ImageContentType) 25 | 26 | /** 27 | * Return image format 28 | * 29 | * @param data the input image data 30 | * 31 | * @return the image format as `SDImageFormat` (enum) 32 | */ 33 | + (SDImageFormat)sd_imageFormatForImageData:(nullable NSData *)data; 34 | 35 | /** 36 | * Convert SDImageFormat to UTType 37 | * 38 | * @param format Format as SDImageFormat 39 | * @return The UTType as CFStringRef 40 | */ 41 | + (nonnull CFStringRef)sd_UTTypeFromSDImageFormat:(SDImageFormat)format; 42 | 43 | /** 44 | * Convert UTTyppe to SDImageFormat 45 | * 46 | * @param uttype The UTType as CFStringRef 47 | * @return The Format as SDImageFormat 48 | */ 49 | + (SDImageFormat)sd_imageFormatFromUTType:(nonnull CFStringRef)uttype; 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/NSImage+WebCache.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | 11 | #if SD_MAC 12 | 13 | #import 14 | 15 | @interface NSImage (WebCache) 16 | 17 | - (CGImageRef)CGImage; 18 | - (NSArray *)images; 19 | - (BOOL)isGIF; 20 | 21 | @end 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/NSImage+WebCache.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "NSImage+WebCache.h" 10 | 11 | #if SD_MAC 12 | 13 | @implementation NSImage (WebCache) 14 | 15 | - (CGImageRef)CGImage { 16 | NSRect imageRect = NSMakeRect(0, 0, self.size.width, self.size.height); 17 | CGImageRef cgImage = [self CGImageForProposedRect:&imageRect context:NULL hints:nil]; 18 | return cgImage; 19 | } 20 | 21 | - (NSArray *)images { 22 | return nil; 23 | } 24 | 25 | - (BOOL)isGIF { 26 | BOOL isGIF = NO; 27 | for (NSImageRep *rep in self.representations) { 28 | if ([rep isKindOfClass:[NSBitmapImageRep class]]) { 29 | NSBitmapImageRep *bitmapRep = (NSBitmapImageRep *)rep; 30 | NSUInteger frameCount = [[bitmapRep valueForProperty:NSImageFrameCount] unsignedIntegerValue]; 31 | isGIF = frameCount > 1 ? YES : NO; 32 | break; 33 | } 34 | } 35 | return isGIF; 36 | } 37 | 38 | @end 39 | 40 | #endif 41 | 42 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDAnimatedImageRep.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | 11 | #if SD_MAC 12 | 13 | // A subclass of `NSBitmapImageRep` to fix that GIF loop count issue because `NSBitmapImageRep` will reset `NSImageCurrentFrameDuration` by using `kCGImagePropertyGIFDelayTime` but not `kCGImagePropertyGIFUnclampedDelayTime`. 14 | // Built in GIF coder use this instead of `NSBitmapImageRep` for better GIF rendering. If you do not want this, only enable `SDWebImageImageIOCoder`, which just call `NSImage` API and actually use `NSBitmapImageRep` for GIF image. 15 | 16 | @interface SDAnimatedImageRep : NSBitmapImageRep 17 | 18 | @end 19 | 20 | #endif 21 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDAnimatedImageRep.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDAnimatedImageRep.h" 10 | 11 | #if SD_MAC 12 | 13 | #import "SDWebImageGIFCoder.h" 14 | 15 | @interface SDWebImageGIFCoder () 16 | 17 | - (float)sd_frameDurationAtIndex:(NSUInteger)index source:(CGImageSourceRef)source; 18 | 19 | @end 20 | 21 | @interface SDAnimatedImageRep () 22 | 23 | @property (nonatomic, assign, readonly, nullable) CGImageSourceRef imageSource; 24 | 25 | @end 26 | 27 | @implementation SDAnimatedImageRep 28 | 29 | // `NSBitmapImageRep` will use `kCGImagePropertyGIFDelayTime` whenever you call `setProperty:withValue:` with `NSImageCurrentFrame` to change the current frame. We override it and use the actual `kCGImagePropertyGIFUnclampedDelayTime` if need. 30 | - (void)setProperty:(NSBitmapImageRepPropertyKey)property withValue:(id)value { 31 | [super setProperty:property withValue:value]; 32 | if ([property isEqualToString:NSImageCurrentFrame]) { 33 | // Access the image source 34 | CGImageSourceRef imageSource = self.imageSource; 35 | if (!imageSource) { 36 | return; 37 | } 38 | // Check format type 39 | CFStringRef type = CGImageSourceGetType(imageSource); 40 | if (!type) { 41 | return; 42 | } 43 | NSUInteger index = [value unsignedIntegerValue]; 44 | float frameDuration = 0; 45 | // Through we currently process GIF only, in the 5.x we support APNG so we keep the extensibility 46 | if (CFStringCompare(type, kUTTypeGIF, 0) == kCFCompareEqualTo) { 47 | frameDuration = [[SDWebImageGIFCoder sharedCoder] sd_frameDurationAtIndex:index source:imageSource]; 48 | } 49 | if (!frameDuration) { 50 | return; 51 | } 52 | // Reset super frame duration with the actual frame duration 53 | [super setProperty:NSImageCurrentFrameDuration withValue:@(frameDuration)]; 54 | } 55 | } 56 | 57 | - (CGImageSourceRef)imageSource { 58 | if (_tiffData) { 59 | return (__bridge CGImageSourceRef)(_tiffData); 60 | } 61 | return NULL; 62 | } 63 | 64 | @end 65 | 66 | #endif 67 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDImageCacheConfig.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCompat.h" 11 | 12 | typedef NS_ENUM(NSUInteger, SDImageCacheConfigExpireType) { 13 | /** 14 | * When the image is accessed it will update this value 15 | */ 16 | SDImageCacheConfigExpireTypeAccessDate, 17 | /** 18 | * The image was obtained from the disk cache (Default) 19 | */ 20 | SDImageCacheConfigExpireTypeModificationDate 21 | }; 22 | 23 | @interface SDImageCacheConfig : NSObject 24 | 25 | /** 26 | * Decompressing images that are downloaded and cached can improve performance but can consume lot of memory. 27 | * Defaults to YES. Set this to NO if you are experiencing a crash due to excessive memory consumption. 28 | */ 29 | @property (assign, nonatomic) BOOL shouldDecompressImages; 30 | 31 | /** 32 | * Whether or not to disable iCloud backup 33 | * Defaults to YES. 34 | */ 35 | @property (assign, nonatomic) BOOL shouldDisableiCloud; 36 | 37 | /** 38 | * Whether or not to use memory cache 39 | * @note When the memory cache is disabled, the weak memory cache will also be disabled. 40 | * Defaults to YES. 41 | */ 42 | @property (assign, nonatomic) BOOL shouldCacheImagesInMemory; 43 | 44 | /** 45 | * The option to control weak memory cache for images. When enable, `SDImageCache`'s memory cache will use a weak maptable to store the image at the same time when it stored to memory, and get removed at the same time. 46 | * However when memory warning is triggered, since the weak maptable does not hold a strong reference to image instacnce, even when the memory cache itself is purged, some images which are held strongly by UIImageViews or other live instances can be recovered again, to avoid later re-query from disk cache or network. This may be helpful for the case, for example, when app enter background and memory is purged, cause cell flashing after re-enter foreground. 47 | * Defautls to YES. You can change this option dynamically. 48 | */ 49 | @property (assign, nonatomic) BOOL shouldUseWeakMemoryCache; 50 | 51 | /** 52 | * The reading options while reading cache from disk. 53 | * Defaults to 0. You can set this to `NSDataReadingMappedIfSafe` to improve performance. 54 | */ 55 | @property (assign, nonatomic) NSDataReadingOptions diskCacheReadingOptions; 56 | 57 | /** 58 | * The writing options while writing cache to disk. 59 | * Defaults to `NSDataWritingAtomic`. You can set this to `NSDataWritingWithoutOverwriting` to prevent overwriting an existing file. 60 | */ 61 | @property (assign, nonatomic) NSDataWritingOptions diskCacheWritingOptions; 62 | 63 | /** 64 | * The maximum length of time to keep an image in the cache, in seconds. 65 | */ 66 | @property (assign, nonatomic) NSInteger maxCacheAge; 67 | 68 | /** 69 | * The maximum size of the cache, in bytes. 70 | */ 71 | @property (assign, nonatomic) NSUInteger maxCacheSize; 72 | 73 | /** 74 | * The attribute which the clear cache will be checked against when clearing the disk cache 75 | * Default is Modified Date 76 | */ 77 | @property (assign, nonatomic) SDImageCacheConfigExpireType diskCacheExpireType; 78 | 79 | @end 80 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDImageCacheConfig.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDImageCacheConfig.h" 10 | 11 | static const NSInteger kDefaultCacheMaxCacheAge = 60 * 60 * 24 * 7; // 1 week 12 | 13 | @implementation SDImageCacheConfig 14 | 15 | - (instancetype)init { 16 | if (self = [super init]) { 17 | _shouldDecompressImages = YES; 18 | _shouldDisableiCloud = YES; 19 | _shouldCacheImagesInMemory = YES; 20 | _shouldUseWeakMemoryCache = YES; 21 | _diskCacheReadingOptions = 0; 22 | _diskCacheWritingOptions = NSDataWritingAtomic; 23 | _maxCacheAge = kDefaultCacheMaxCacheAge; 24 | _maxCacheSize = 0; 25 | _diskCacheExpireType = SDImageCacheConfigExpireTypeModificationDate; 26 | } 27 | return self; 28 | } 29 | 30 | @end 31 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCoder.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCompat.h" 11 | #import "NSData+ImageContentType.h" 12 | 13 | /** 14 | A Boolean value indicating whether to scale down large images during decompressing. (NSNumber) 15 | */ 16 | FOUNDATION_EXPORT NSString * _Nonnull const SDWebImageCoderScaleDownLargeImagesKey; 17 | 18 | /** 19 | Return the shared device-dependent RGB color space created with CGColorSpaceCreateDeviceRGB. 20 | 21 | @return The device-dependent RGB color space 22 | */ 23 | CG_EXTERN CGColorSpaceRef _Nonnull SDCGColorSpaceGetDeviceRGB(void); 24 | 25 | /** 26 | Check whether CGImageRef contains alpha channel. 27 | 28 | @param imageRef The CGImageRef 29 | @return Return YES if CGImageRef contains alpha channel, otherwise return NO 30 | */ 31 | CG_EXTERN BOOL SDCGImageRefContainsAlpha(_Nullable CGImageRef imageRef); 32 | 33 | 34 | /** 35 | This is the image coder protocol to provide custom image decoding/encoding. 36 | These methods are all required to implement. 37 | @note Pay attention that these methods are not called from main queue. 38 | */ 39 | @protocol SDWebImageCoder 40 | 41 | @required 42 | #pragma mark - Decoding 43 | /** 44 | Returns YES if this coder can decode some data. Otherwise, the data should be passed to another coder. 45 | 46 | @param data The image data so we can look at it 47 | @return YES if this coder can decode the data, NO otherwise 48 | */ 49 | - (BOOL)canDecodeFromData:(nullable NSData *)data; 50 | 51 | /** 52 | Decode the image data to image. 53 | 54 | @param data The image data to be decoded 55 | @return The decoded image from data 56 | */ 57 | - (nullable UIImage *)decodedImageWithData:(nullable NSData *)data; 58 | 59 | /** 60 | Decompress the image with original image and image data. 61 | 62 | @param image The original image to be decompressed 63 | @param data The pointer to original image data. The pointer itself is nonnull but image data can be null. This data will set to cache if needed. If you do not need to modify data at the sametime, ignore this param. 64 | @param optionsDict A dictionary containing any decompressing options. Pass {SDWebImageCoderScaleDownLargeImagesKey: @(YES)} to scale down large images 65 | @return The decompressed image 66 | */ 67 | - (nullable UIImage *)decompressedImageWithImage:(nullable UIImage *)image 68 | data:(NSData * _Nullable * _Nonnull)data 69 | options:(nullable NSDictionary*)optionsDict; 70 | 71 | #pragma mark - Encoding 72 | 73 | /** 74 | Returns YES if this coder can encode some image. Otherwise, it should be passed to another coder. 75 | 76 | @param format The image format 77 | @return YES if this coder can encode the image, NO otherwise 78 | */ 79 | - (BOOL)canEncodeToFormat:(SDImageFormat)format; 80 | 81 | /** 82 | Encode the image to image data. 83 | 84 | @param image The image to be encoded 85 | @param format The image format to encode, you should note `SDImageFormatUndefined` format is also possible 86 | @return The encoded image data 87 | */ 88 | - (nullable NSData *)encodedDataWithImage:(nullable UIImage *)image format:(SDImageFormat)format; 89 | 90 | @end 91 | 92 | 93 | /** 94 | This is the image coder protocol to provide custom progressive image decoding. 95 | These methods are all required to implement. 96 | @note Pay attention that these methods are not called from main queue. 97 | */ 98 | @protocol SDWebImageProgressiveCoder 99 | 100 | @required 101 | /** 102 | Returns YES if this coder can incremental decode some data. Otherwise, it should be passed to another coder. 103 | 104 | @param data The image data so we can look at it 105 | @return YES if this coder can decode the data, NO otherwise 106 | */ 107 | - (BOOL)canIncrementallyDecodeFromData:(nullable NSData *)data; 108 | 109 | /** 110 | Incremental decode the image data to image. 111 | 112 | @param data The image data has been downloaded so far 113 | @param finished Whether the download has finished 114 | @warning because incremental decoding need to keep the decoded context, we will alloc a new instance with the same class for each download operation to avoid conflicts 115 | @return The decoded image from data 116 | */ 117 | - (nullable UIImage *)incrementallyDecodedImageWithData:(nullable NSData *)data finished:(BOOL)finished; 118 | 119 | @end 120 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCoder.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCoder.h" 10 | 11 | NSString * const SDWebImageCoderScaleDownLargeImagesKey = @"scaleDownLargeImages"; 12 | 13 | CGColorSpaceRef SDCGColorSpaceGetDeviceRGB(void) { 14 | static CGColorSpaceRef colorSpace; 15 | static dispatch_once_t onceToken; 16 | dispatch_once(&onceToken, ^{ 17 | colorSpace = CGColorSpaceCreateDeviceRGB(); 18 | }); 19 | return colorSpace; 20 | } 21 | 22 | BOOL SDCGImageRefContainsAlpha(CGImageRef imageRef) { 23 | if (!imageRef) { 24 | return NO; 25 | } 26 | CGImageAlphaInfo alphaInfo = CGImageGetAlphaInfo(imageRef); 27 | BOOL hasAlpha = !(alphaInfo == kCGImageAlphaNone || 28 | alphaInfo == kCGImageAlphaNoneSkipFirst || 29 | alphaInfo == kCGImageAlphaNoneSkipLast); 30 | return hasAlpha; 31 | } 32 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCoderHelper.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCompat.h" 11 | #import "SDWebImageFrame.h" 12 | 13 | @interface SDWebImageCoderHelper : NSObject 14 | 15 | /** 16 | Return an animated image with frames array. 17 | For UIKit, this will apply the patch and then create animated UIImage. The patch is because that `+[UIImage animatedImageWithImages:duration:]` just use the average of duration for each image. So it will not work if different frame has different duration. Therefore we repeat the specify frame for specify times to let it work. 18 | For AppKit, NSImage does not support animates other than GIF. This will try to encode the frames to GIF format and then create an animated NSImage for rendering. Attention the animated image may loss some detail if the input frames contain full alpha channel because GIF only supports 1 bit alpha channel. (For 1 pixel, either transparent or not) 19 | 20 | @param frames The frames array. If no frames or frames is empty, return nil 21 | @return A animated image for rendering on UIImageView(UIKit) or NSImageView(AppKit) 22 | */ 23 | + (UIImage * _Nullable)animatedImageWithFrames:(NSArray * _Nullable)frames; 24 | 25 | /** 26 | Return frames array from an animated image. 27 | For UIKit, this will unapply the patch for the description above and then create frames array. This will also work for normal animated UIImage. 28 | For AppKit, NSImage does not support animates other than GIF. This will try to decode the GIF imageRep and then create frames array. 29 | 30 | @param animatedImage A animated image. If it's not animated, return nil 31 | @return The frames array 32 | */ 33 | + (NSArray * _Nullable)framesFromAnimatedImage:(UIImage * _Nullable)animatedImage; 34 | 35 | #if SD_UIKIT || SD_WATCH 36 | /** 37 | Convert an EXIF image orientation to an iOS one. 38 | 39 | @param exifOrientation EXIF orientation 40 | @return iOS orientation 41 | */ 42 | + (UIImageOrientation)imageOrientationFromEXIFOrientation:(NSInteger)exifOrientation; 43 | /** 44 | Convert an iOS orientation to an EXIF image orientation. 45 | 46 | @param imageOrientation iOS orientation 47 | @return EXIF orientation 48 | */ 49 | + (NSInteger)exifOrientationFromImageOrientation:(UIImageOrientation)imageOrientation; 50 | #endif 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCodersManager.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCoder.h" 11 | 12 | /** 13 | Global object holding the array of coders, so that we avoid passing them from object to object. 14 | Uses a priority queue behind scenes, which means the latest added coders have the highest priority. 15 | This is done so when encoding/decoding something, we go through the list and ask each coder if they can handle the current data. 16 | That way, users can add their custom coders while preserving our existing prebuilt ones 17 | 18 | Note: the `coders` getter will return the coders in their reversed order 19 | Example: 20 | - by default we internally set coders = `IOCoder`, `WebPCoder`. (`GIFCoder` is not recommended to add only if you want to get GIF support without `FLAnimatedImage`) 21 | - calling `coders` will return `@[WebPCoder, IOCoder]` 22 | - call `[addCoder:[MyCrazyCoder new]]` 23 | - calling `coders` now returns `@[MyCrazyCoder, WebPCoder, IOCoder]` 24 | 25 | Coders 26 | ------ 27 | A coder must conform to the `SDWebImageCoder` protocol or even to `SDWebImageProgressiveCoder` if it supports progressive decoding 28 | Conformance is important because that way, they will implement `canDecodeFromData` or `canEncodeToFormat` 29 | Those methods are called on each coder in the array (using the priority order) until one of them returns YES. 30 | That means that coder can decode that data / encode to that format 31 | */ 32 | @interface SDWebImageCodersManager : NSObject 33 | 34 | /** 35 | Shared reusable instance 36 | */ 37 | + (nonnull instancetype)sharedInstance; 38 | 39 | /** 40 | All coders in coders manager. The coders array is a priority queue, which means the later added coder will have the highest priority 41 | */ 42 | @property (nonatomic, copy, readwrite, nullable) NSArray> *coders; 43 | 44 | /** 45 | Add a new coder to the end of coders array. Which has the highest priority. 46 | 47 | @param coder coder 48 | */ 49 | - (void)addCoder:(nonnull id)coder; 50 | 51 | /** 52 | Remove a coder in the coders array. 53 | 54 | @param coder coder 55 | */ 56 | - (void)removeCoder:(nonnull id)coder; 57 | 58 | @end 59 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCompat.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * (c) Jamie Pinkham 5 | * 6 | * For the full copyright and license information, please view the LICENSE 7 | * file that was distributed with this source code. 8 | */ 9 | 10 | #import 11 | 12 | #ifdef __OBJC_GC__ 13 | #error SDWebImage does not support Objective-C Garbage Collection 14 | #endif 15 | 16 | // Apple's defines from TargetConditionals.h are a bit weird. 17 | // Seems like TARGET_OS_MAC is always defined (on all platforms). 18 | // To determine if we are running on OSX, we can only rely on TARGET_OS_IPHONE=0 and all the other platforms 19 | #if !TARGET_OS_IPHONE && !TARGET_OS_IOS && !TARGET_OS_TV && !TARGET_OS_WATCH 20 | #define SD_MAC 1 21 | #else 22 | #define SD_MAC 0 23 | #endif 24 | 25 | // iOS and tvOS are very similar, UIKit exists on both platforms 26 | // Note: watchOS also has UIKit, but it's very limited 27 | #if TARGET_OS_IOS || TARGET_OS_TV 28 | #define SD_UIKIT 1 29 | #else 30 | #define SD_UIKIT 0 31 | #endif 32 | 33 | #if TARGET_OS_IOS 34 | #define SD_IOS 1 35 | #else 36 | #define SD_IOS 0 37 | #endif 38 | 39 | #if TARGET_OS_TV 40 | #define SD_TV 1 41 | #else 42 | #define SD_TV 0 43 | #endif 44 | 45 | #if TARGET_OS_WATCH 46 | #define SD_WATCH 1 47 | #else 48 | #define SD_WATCH 0 49 | #endif 50 | 51 | 52 | #if SD_MAC 53 | #import 54 | #ifndef UIImage 55 | #define UIImage NSImage 56 | #endif 57 | #ifndef UIImageView 58 | #define UIImageView NSImageView 59 | #endif 60 | #ifndef UIView 61 | #define UIView NSView 62 | #endif 63 | #else 64 | #if __IPHONE_OS_VERSION_MIN_REQUIRED != 20000 && __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_5_0 65 | #error SDWebImage doesn't support Deployment Target version < 5.0 66 | #endif 67 | 68 | #if SD_UIKIT 69 | #import 70 | #endif 71 | #if SD_WATCH 72 | #import 73 | #ifndef UIView 74 | #define UIView WKInterfaceObject 75 | #endif 76 | #ifndef UIImageView 77 | #define UIImageView WKInterfaceImage 78 | #endif 79 | #endif 80 | #endif 81 | 82 | #ifndef NS_ENUM 83 | #define NS_ENUM(_type, _name) enum _name : _type _name; enum _name : _type 84 | #endif 85 | 86 | #ifndef NS_OPTIONS 87 | #define NS_OPTIONS(_type, _name) enum _name : _type _name; enum _name : _type 88 | #endif 89 | 90 | FOUNDATION_EXPORT UIImage *SDScaledImageForKey(NSString *key, UIImage *image); 91 | 92 | typedef void(^SDWebImageNoParamsBlock)(void); 93 | 94 | FOUNDATION_EXPORT NSString *const SDWebImageErrorDomain; 95 | 96 | #ifndef dispatch_queue_async_safe 97 | #define dispatch_queue_async_safe(queue, block)\ 98 | if (dispatch_queue_get_label(DISPATCH_CURRENT_QUEUE_LABEL) == dispatch_queue_get_label(queue)) {\ 99 | block();\ 100 | } else {\ 101 | dispatch_async(queue, block);\ 102 | } 103 | #endif 104 | 105 | #ifndef dispatch_main_async_safe 106 | #define dispatch_main_async_safe(block) dispatch_queue_async_safe(dispatch_get_main_queue(), block) 107 | #endif 108 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageCompat.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | #import "UIImage+MultiFormat.h" 11 | 12 | #if !__has_feature(objc_arc) 13 | #error SDWebImage is ARC only. Either turn on ARC for the project or use -fobjc-arc flag 14 | #endif 15 | 16 | #if !OS_OBJECT_USE_OBJC 17 | #error SDWebImage need ARC for dispatch object 18 | #endif 19 | 20 | inline UIImage *SDScaledImageForKey(NSString * _Nullable key, UIImage * _Nullable image) { 21 | if (!image) { 22 | return nil; 23 | } 24 | 25 | #if SD_MAC 26 | return image; 27 | #elif SD_UIKIT || SD_WATCH 28 | if ((image.images).count > 0) { 29 | NSMutableArray *scaledImages = [NSMutableArray array]; 30 | 31 | for (UIImage *tempImage in image.images) { 32 | [scaledImages addObject:SDScaledImageForKey(key, tempImage)]; 33 | } 34 | 35 | UIImage *animatedImage = [UIImage animatedImageWithImages:scaledImages duration:image.duration]; 36 | if (animatedImage) { 37 | animatedImage.sd_imageLoopCount = image.sd_imageLoopCount; 38 | animatedImage.sd_imageFormat = image.sd_imageFormat; 39 | } 40 | return animatedImage; 41 | } else { 42 | #if SD_WATCH 43 | if ([[WKInterfaceDevice currentDevice] respondsToSelector:@selector(screenScale)]) { 44 | #elif SD_UIKIT 45 | if ([[UIScreen mainScreen] respondsToSelector:@selector(scale)]) { 46 | #endif 47 | CGFloat scale = 1; 48 | if (key.length >= 8) { 49 | NSRange range = [key rangeOfString:@"@2x."]; 50 | if (range.location != NSNotFound) { 51 | scale = 2.0; 52 | } 53 | 54 | range = [key rangeOfString:@"@3x."]; 55 | if (range.location != NSNotFound) { 56 | scale = 3.0; 57 | } 58 | } 59 | 60 | if (scale != image.scale) { 61 | UIImage *scaledImage = [[UIImage alloc] initWithCGImage:image.CGImage scale:scale orientation:image.imageOrientation]; 62 | scaledImage.sd_imageFormat = image.sd_imageFormat; 63 | image = scaledImage; 64 | } 65 | } 66 | return image; 67 | } 68 | #endif 69 | } 70 | 71 | NSString *const SDWebImageErrorDomain = @"SDWebImageErrorDomain"; 72 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageFrame.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCompat.h" 11 | 12 | @interface SDWebImageFrame : NSObject 13 | 14 | // This class is used for creating animated images via `animatedImageWithFrames` in `SDWebImageCoderHelper`. Attention if you need to specify animated images loop count, use `sd_imageLoopCount` property in `UIImage+MultiFormat`. 15 | 16 | /** 17 | The image of current frame. You should not set an animated image. 18 | */ 19 | @property (nonatomic, strong, readonly, nonnull) UIImage *image; 20 | /** 21 | The duration of current frame to be displayed. The number is seconds but not milliseconds. You should not set this to zero. 22 | */ 23 | @property (nonatomic, readonly, assign) NSTimeInterval duration; 24 | 25 | /** 26 | Create a frame instance with specify image and duration 27 | 28 | @param image current frame's image 29 | @param duration current frame's duration 30 | @return frame instance 31 | */ 32 | + (instancetype _Nonnull)frameWithImage:(UIImage * _Nonnull)image duration:(NSTimeInterval)duration; 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageFrame.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageFrame.h" 10 | 11 | @interface SDWebImageFrame () 12 | 13 | @property (nonatomic, strong, readwrite, nonnull) UIImage *image; 14 | @property (nonatomic, readwrite, assign) NSTimeInterval duration; 15 | 16 | @end 17 | 18 | @implementation SDWebImageFrame 19 | 20 | + (instancetype)frameWithImage:(UIImage *)image duration:(NSTimeInterval)duration { 21 | SDWebImageFrame *frame = [[SDWebImageFrame alloc] init]; 22 | frame.image = image; 23 | frame.duration = duration; 24 | 25 | return frame; 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageGIFCoder.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCoder.h" 11 | 12 | /** 13 | Built in coder using ImageIO that supports GIF encoding/decoding 14 | @note `SDWebImageIOCoder` supports GIF but only as static (will use the 1st frame). 15 | @note Use `SDWebImageGIFCoder` for fully animated GIFs - less performant than `FLAnimatedImage` 16 | @note If you decide to make all `UIImageView`(including `FLAnimatedImageView`) instance support GIF. You should add this coder to `SDWebImageCodersManager` and make sure that it has a higher priority than `SDWebImageIOCoder` 17 | @note The recommended approach for animated GIFs is using `FLAnimatedImage`. It's more performant than `UIImageView` for GIF displaying 18 | */ 19 | @interface SDWebImageGIFCoder : NSObject 20 | 21 | + (nonnull instancetype)sharedCoder; 22 | 23 | @end 24 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageImageIOCoder.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageCoder.h" 11 | 12 | /** 13 | Built in coder that supports PNG, JPEG, TIFF, includes support for progressive decoding. 14 | 15 | GIF 16 | Also supports static GIF (meaning will only handle the 1st frame). 17 | For a full GIF support, we recommend `FLAnimatedImage` or our less performant `SDWebImageGIFCoder` 18 | 19 | HEIC 20 | This coder also supports HEIC format because ImageIO supports it natively. But it depends on the system capabilities, so it won't work on all devices, see: https://devstreaming-cdn.apple.com/videos/wwdc/2017/511tj33587vdhds/511/511_working_with_heif_and_hevc.pdf 21 | Decode(Software): !Simulator && (iOS 11 || tvOS 11 || macOS 10.13) 22 | Decode(Hardware): !Simulator && ((iOS 11 && A9Chip) || (macOS 10.13 && 6thGenerationIntelCPU)) 23 | Encode(Software): macOS 10.13 24 | Encode(Hardware): !Simulator && ((iOS 11 && A10FusionChip) || (macOS 10.13 && 6thGenerationIntelCPU)) 25 | */ 26 | @interface SDWebImageImageIOCoder : NSObject 27 | 28 | + (nonnull instancetype)sharedCoder; 29 | 30 | @end 31 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImageOperation.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | 11 | @protocol SDWebImageOperation 12 | 13 | - (void)cancel; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/SDWebImagePrefetcher.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import 10 | #import "SDWebImageManager.h" 11 | 12 | @class SDWebImagePrefetcher; 13 | 14 | @protocol SDWebImagePrefetcherDelegate 15 | 16 | @optional 17 | 18 | /** 19 | * Called when an image was prefetched. 20 | * 21 | * @param imagePrefetcher The current image prefetcher 22 | * @param imageURL The image url that was prefetched 23 | * @param finishedCount The total number of images that were prefetched (successful or not) 24 | * @param totalCount The total number of images that were to be prefetched 25 | */ 26 | - (void)imagePrefetcher:(nonnull SDWebImagePrefetcher *)imagePrefetcher didPrefetchURL:(nullable NSURL *)imageURL finishedCount:(NSUInteger)finishedCount totalCount:(NSUInteger)totalCount; 27 | 28 | /** 29 | * Called when all images are prefetched. 30 | * @param imagePrefetcher The current image prefetcher 31 | * @param totalCount The total number of images that were prefetched (whether successful or not) 32 | * @param skippedCount The total number of images that were skipped 33 | */ 34 | - (void)imagePrefetcher:(nonnull SDWebImagePrefetcher *)imagePrefetcher didFinishWithTotalCount:(NSUInteger)totalCount skippedCount:(NSUInteger)skippedCount; 35 | 36 | @end 37 | 38 | typedef void(^SDWebImagePrefetcherProgressBlock)(NSUInteger noOfFinishedUrls, NSUInteger noOfTotalUrls); 39 | typedef void(^SDWebImagePrefetcherCompletionBlock)(NSUInteger noOfFinishedUrls, NSUInteger noOfSkippedUrls); 40 | 41 | /** 42 | * Prefetch some URLs in the cache for future use. Images are downloaded in low priority. 43 | */ 44 | @interface SDWebImagePrefetcher : NSObject 45 | 46 | /** 47 | * The web image manager 48 | */ 49 | @property (strong, nonatomic, readonly, nonnull) SDWebImageManager *manager; 50 | 51 | /** 52 | * Maximum number of URLs to prefetch at the same time. Defaults to 3. 53 | */ 54 | @property (nonatomic, assign) NSUInteger maxConcurrentDownloads; 55 | 56 | /** 57 | * SDWebImageOptions for prefetcher. Defaults to SDWebImageLowPriority. 58 | */ 59 | @property (nonatomic, assign) SDWebImageOptions options; 60 | 61 | /** 62 | * Queue options for Prefetcher. Defaults to Main Queue. 63 | */ 64 | @property (strong, nonatomic, nonnull) dispatch_queue_t prefetcherQueue; 65 | 66 | @property (weak, nonatomic, nullable) id delegate; 67 | 68 | /** 69 | * Return the global image prefetcher instance. 70 | */ 71 | + (nonnull instancetype)sharedImagePrefetcher; 72 | 73 | /** 74 | * Allows you to instantiate a prefetcher with any arbitrary image manager. 75 | */ 76 | - (nonnull instancetype)initWithImageManager:(nonnull SDWebImageManager *)manager NS_DESIGNATED_INITIALIZER; 77 | 78 | /** 79 | * Assign list of URLs to let SDWebImagePrefetcher to queue the prefetching, 80 | * currently one image is downloaded at a time, 81 | * and skips images for failed downloads and proceed to the next image in the list. 82 | * Any previously-running prefetch operations are canceled. 83 | * 84 | * @param urls list of URLs to prefetch 85 | */ 86 | - (void)prefetchURLs:(nullable NSArray *)urls; 87 | 88 | /** 89 | * Assign list of URLs to let SDWebImagePrefetcher to queue the prefetching, 90 | * currently one image is downloaded at a time, 91 | * and skips images for failed downloads and proceed to the next image in the list. 92 | * Any previously-running prefetch operations are canceled. 93 | * 94 | * @param urls list of URLs to prefetch 95 | * @param progressBlock block to be called when progress updates; 96 | * first parameter is the number of completed (successful or not) requests, 97 | * second parameter is the total number of images originally requested to be prefetched 98 | * @param completionBlock block to be called when prefetching is completed 99 | * first param is the number of completed (successful or not) requests, 100 | * second parameter is the number of skipped requests 101 | */ 102 | - (void)prefetchURLs:(nullable NSArray *)urls 103 | progress:(nullable SDWebImagePrefetcherProgressBlock)progressBlock 104 | completed:(nullable SDWebImagePrefetcherCompletionBlock)completionBlock; 105 | 106 | /** 107 | * Remove and cancel queued list 108 | */ 109 | - (void)cancelPrefetching; 110 | 111 | 112 | @end 113 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+ForceDecode.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | 11 | @interface UIImage (ForceDecode) 12 | 13 | + (nullable UIImage *)decodedImageWithImage:(nullable UIImage *)image; 14 | 15 | + (nullable UIImage *)decodedAndScaledDownImageWithImage:(nullable UIImage *)image; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+ForceDecode.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "UIImage+ForceDecode.h" 10 | #import "SDWebImageCodersManager.h" 11 | 12 | @implementation UIImage (ForceDecode) 13 | 14 | + (UIImage *)decodedImageWithImage:(UIImage *)image { 15 | if (!image) { 16 | return nil; 17 | } 18 | NSData *tempData; 19 | return [[SDWebImageCodersManager sharedInstance] decompressedImageWithImage:image data:&tempData options:@{SDWebImageCoderScaleDownLargeImagesKey: @(NO)}]; 20 | } 21 | 22 | + (UIImage *)decodedAndScaledDownImageWithImage:(UIImage *)image { 23 | if (!image) { 24 | return nil; 25 | } 26 | NSData *tempData; 27 | return [[SDWebImageCodersManager sharedInstance] decompressedImageWithImage:image data:&tempData options:@{SDWebImageCoderScaleDownLargeImagesKey: @(YES)}]; 28 | } 29 | 30 | @end 31 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+GIF.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * (c) Laurin Brandner 5 | * 6 | * For the full copyright and license information, please view the LICENSE 7 | * file that was distributed with this source code. 8 | */ 9 | 10 | #import "SDWebImageCompat.h" 11 | 12 | @interface UIImage (GIF) 13 | 14 | /** 15 | * Creates an animated UIImage from an NSData. 16 | * For static GIF, will create an UIImage with `images` array set to nil. For animated GIF, will create an UIImage with valid `images` array. 17 | */ 18 | + (UIImage *)sd_animatedGIFWithData:(NSData *)data; 19 | 20 | /** 21 | * Checks if an UIImage instance is a GIF. Will use the `images` array. 22 | */ 23 | - (BOOL)isGIF; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+GIF.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * (c) Laurin Brandner 5 | * 6 | * For the full copyright and license information, please view the LICENSE 7 | * file that was distributed with this source code. 8 | */ 9 | 10 | #import "UIImage+GIF.h" 11 | #import "SDWebImageGIFCoder.h" 12 | #import "NSImage+WebCache.h" 13 | 14 | @implementation UIImage (GIF) 15 | 16 | + (UIImage *)sd_animatedGIFWithData:(NSData *)data { 17 | if (!data) { 18 | return nil; 19 | } 20 | return [[SDWebImageGIFCoder sharedCoder] decodedImageWithData:data]; 21 | } 22 | 23 | - (BOOL)isGIF { 24 | return (self.images != nil); 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+MultiFormat.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | #import "NSData+ImageContentType.h" 11 | 12 | @interface UIImage (MultiFormat) 13 | 14 | /** 15 | * UIKit: 16 | * For static image format, this value is always 0. 17 | * For animated image format, 0 means infinite looping. 18 | * @note Note that because of the limitations of categories this property can get out of sync if you create another instance with CGImage or other methods. 19 | * AppKit: 20 | * NSImage currently only support animated via GIF imageRep unlike UIImage. 21 | * The getter of this property will get the loop count from GIF imageRep 22 | * The setter of this property will set the loop count from GIF imageRep 23 | */ 24 | @property (nonatomic, assign) NSUInteger sd_imageLoopCount; 25 | 26 | /** 27 | * The image format represent the original compressed image data format. 28 | * If you don't manually specify a format, this information is retrieve from CGImage using `CGImageGetUTType`, which may return nil for non-CG based image. At this time it will return `SDImageFormatUndefined` as default value. 29 | * @note Note that because of the limitations of categories this property can get out of sync if you create another instance with CGImage or other methods. 30 | */ 31 | @property (nonatomic, assign) SDImageFormat sd_imageFormat; 32 | 33 | + (nullable UIImage *)sd_imageWithData:(nullable NSData *)data; 34 | - (nullable NSData *)sd_imageData; 35 | - (nullable NSData *)sd_imageDataAsFormat:(SDImageFormat)imageFormat; 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImage+MultiFormat.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "UIImage+MultiFormat.h" 10 | #import "NSImage+WebCache.h" 11 | #import "SDWebImageCodersManager.h" 12 | #import "objc/runtime.h" 13 | 14 | @implementation UIImage (MultiFormat) 15 | 16 | #if SD_MAC 17 | - (NSUInteger)sd_imageLoopCount { 18 | NSUInteger imageLoopCount = 0; 19 | for (NSImageRep *rep in self.representations) { 20 | if ([rep isKindOfClass:[NSBitmapImageRep class]]) { 21 | NSBitmapImageRep *bitmapRep = (NSBitmapImageRep *)rep; 22 | imageLoopCount = [[bitmapRep valueForProperty:NSImageLoopCount] unsignedIntegerValue]; 23 | break; 24 | } 25 | } 26 | return imageLoopCount; 27 | } 28 | 29 | - (void)setSd_imageLoopCount:(NSUInteger)sd_imageLoopCount { 30 | for (NSImageRep *rep in self.representations) { 31 | if ([rep isKindOfClass:[NSBitmapImageRep class]]) { 32 | NSBitmapImageRep *bitmapRep = (NSBitmapImageRep *)rep; 33 | [bitmapRep setProperty:NSImageLoopCount withValue:@(sd_imageLoopCount)]; 34 | break; 35 | } 36 | } 37 | } 38 | 39 | #else 40 | 41 | - (NSUInteger)sd_imageLoopCount { 42 | NSUInteger imageLoopCount = 0; 43 | NSNumber *value = objc_getAssociatedObject(self, @selector(sd_imageLoopCount)); 44 | if ([value isKindOfClass:[NSNumber class]]) { 45 | imageLoopCount = value.unsignedIntegerValue; 46 | } 47 | return imageLoopCount; 48 | } 49 | 50 | - (void)setSd_imageLoopCount:(NSUInteger)sd_imageLoopCount { 51 | NSNumber *value = @(sd_imageLoopCount); 52 | objc_setAssociatedObject(self, @selector(sd_imageLoopCount), value, OBJC_ASSOCIATION_RETAIN_NONATOMIC); 53 | } 54 | #endif 55 | 56 | - (SDImageFormat)sd_imageFormat { 57 | SDImageFormat imageFormat = SDImageFormatUndefined; 58 | NSNumber *value = objc_getAssociatedObject(self, @selector(sd_imageFormat)); 59 | if ([value isKindOfClass:[NSNumber class]]) { 60 | imageFormat = value.integerValue; 61 | return imageFormat; 62 | } 63 | // Check CGImage's UTType, may return nil for non-Image/IO based image 64 | #pragma clang diagnostic push 65 | #pragma clang diagnostic ignored "-Wunguarded-availability" 66 | if (&CGImageGetUTType != NULL) { 67 | CFStringRef uttype = CGImageGetUTType(self.CGImage); 68 | imageFormat = [NSData sd_imageFormatFromUTType:uttype]; 69 | } 70 | #pragma clang diagnostic pop 71 | return imageFormat; 72 | } 73 | 74 | - (void)setSd_imageFormat:(SDImageFormat)sd_imageFormat { 75 | objc_setAssociatedObject(self, @selector(sd_imageFormat), @(sd_imageFormat), OBJC_ASSOCIATION_RETAIN_NONATOMIC); 76 | } 77 | 78 | + (nullable UIImage *)sd_imageWithData:(nullable NSData *)data { 79 | return [[SDWebImageCodersManager sharedInstance] decodedImageWithData:data]; 80 | } 81 | 82 | - (nullable NSData *)sd_imageData { 83 | return [self sd_imageDataAsFormat:SDImageFormatUndefined]; 84 | } 85 | 86 | - (nullable NSData *)sd_imageDataAsFormat:(SDImageFormat)imageFormat { 87 | NSData *imageData = nil; 88 | if (self) { 89 | imageData = [[SDWebImageCodersManager sharedInstance] encodedDataWithImage:self format:imageFormat]; 90 | } 91 | return imageData; 92 | } 93 | 94 | 95 | @end 96 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImageView+HighlightedWebCache.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | 11 | #if SD_UIKIT 12 | 13 | #import "SDWebImageManager.h" 14 | 15 | /** 16 | * Integrates SDWebImage async downloading and caching of remote images with UIImageView for highlighted state. 17 | */ 18 | @interface UIImageView (HighlightedWebCache) 19 | 20 | /** 21 | * Set the imageView `highlightedImage` with an `url`. 22 | * 23 | * The download is asynchronous and cached. 24 | * 25 | * @param url The url for the image. 26 | */ 27 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url NS_REFINED_FOR_SWIFT; 28 | 29 | /** 30 | * Set the imageView `highlightedImage` with an `url` and custom options. 31 | * 32 | * The download is asynchronous and cached. 33 | * 34 | * @param url The url for the image. 35 | * @param options The options to use when downloading the image. @see SDWebImageOptions for the possible values. 36 | */ 37 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url 38 | options:(SDWebImageOptions)options NS_REFINED_FOR_SWIFT; 39 | 40 | /** 41 | * Set the imageView `highlightedImage` with an `url`. 42 | * 43 | * The download is asynchronous and cached. 44 | * 45 | * @param url The url for the image. 46 | * @param completedBlock A block called when operation has been completed. This block has no return value 47 | * and takes the requested UIImage as first parameter. In case of error the image parameter 48 | * is nil and the second parameter may contain an NSError. The third parameter is a Boolean 49 | * indicating if the image was retrieved from the local cache or from the network. 50 | * The fourth parameter is the original image url. 51 | */ 52 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url 53 | completed:(nullable SDExternalCompletionBlock)completedBlock NS_REFINED_FOR_SWIFT; 54 | 55 | /** 56 | * Set the imageView `highlightedImage` with an `url` and custom options. 57 | * 58 | * The download is asynchronous and cached. 59 | * 60 | * @param url The url for the image. 61 | * @param options The options to use when downloading the image. @see SDWebImageOptions for the possible values. 62 | * @param completedBlock A block called when operation has been completed. This block has no return value 63 | * and takes the requested UIImage as first parameter. In case of error the image parameter 64 | * is nil and the second parameter may contain an NSError. The third parameter is a Boolean 65 | * indicating if the image was retrieved from the local cache or from the network. 66 | * The fourth parameter is the original image url. 67 | */ 68 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url 69 | options:(SDWebImageOptions)options 70 | completed:(nullable SDExternalCompletionBlock)completedBlock; 71 | 72 | /** 73 | * Set the imageView `highlightedImage` with an `url` and custom options. 74 | * 75 | * The download is asynchronous and cached. 76 | * 77 | * @param url The url for the image. 78 | * @param options The options to use when downloading the image. @see SDWebImageOptions for the possible values. 79 | * @param progressBlock A block called while image is downloading 80 | * @note the progress block is executed on a background queue 81 | * @param completedBlock A block called when operation has been completed. This block has no return value 82 | * and takes the requested UIImage as first parameter. In case of error the image parameter 83 | * is nil and the second parameter may contain an NSError. The third parameter is a Boolean 84 | * indicating if the image was retrieved from the local cache or from the network. 85 | * The fourth parameter is the original image url. 86 | */ 87 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url 88 | options:(SDWebImageOptions)options 89 | progress:(nullable SDWebImageDownloaderProgressBlock)progressBlock 90 | completed:(nullable SDExternalCompletionBlock)completedBlock; 91 | 92 | @end 93 | 94 | #endif 95 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIImageView+HighlightedWebCache.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "UIImageView+HighlightedWebCache.h" 10 | 11 | #if SD_UIKIT 12 | 13 | #import "UIView+WebCacheOperation.h" 14 | #import "UIView+WebCache.h" 15 | 16 | @implementation UIImageView (HighlightedWebCache) 17 | 18 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url { 19 | [self sd_setHighlightedImageWithURL:url options:0 progress:nil completed:nil]; 20 | } 21 | 22 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url options:(SDWebImageOptions)options { 23 | [self sd_setHighlightedImageWithURL:url options:options progress:nil completed:nil]; 24 | } 25 | 26 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url completed:(nullable SDExternalCompletionBlock)completedBlock { 27 | [self sd_setHighlightedImageWithURL:url options:0 progress:nil completed:completedBlock]; 28 | } 29 | 30 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url options:(SDWebImageOptions)options completed:(nullable SDExternalCompletionBlock)completedBlock { 31 | [self sd_setHighlightedImageWithURL:url options:options progress:nil completed:completedBlock]; 32 | } 33 | 34 | - (void)sd_setHighlightedImageWithURL:(nullable NSURL *)url 35 | options:(SDWebImageOptions)options 36 | progress:(nullable SDWebImageDownloaderProgressBlock)progressBlock 37 | completed:(nullable SDExternalCompletionBlock)completedBlock { 38 | __weak typeof(self)weakSelf = self; 39 | [self sd_internalSetImageWithURL:url 40 | placeholderImage:nil 41 | options:options 42 | operationKey:@"UIImageViewImageOperationHighlighted" 43 | setImageBlock:^(UIImage *image, NSData *imageData) { 44 | weakSelf.highlightedImage = image; 45 | } 46 | progress:progressBlock 47 | completed:completedBlock]; 48 | } 49 | 50 | @end 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIView+WebCacheOperation.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "SDWebImageCompat.h" 10 | #import "SDWebImageOperation.h" 11 | 12 | // These methods are used to support canceling for UIView image loading, it's designed to be used internal but not external. 13 | // All the stored operations are weak, so it will be dalloced after image loading finished. If you need to store operations, use your own class to keep a strong reference for them. 14 | @interface UIView (WebCacheOperation) 15 | 16 | /** 17 | * Set the image load operation (storage in a UIView based weak map table) 18 | * 19 | * @param operation the operation 20 | * @param key key for storing the operation 21 | */ 22 | - (void)sd_setImageLoadOperation:(nullable id)operation forKey:(nullable NSString *)key; 23 | 24 | /** 25 | * Cancel all operations for the current UIView and key 26 | * 27 | * @param key key for identifying the operations 28 | */ 29 | - (void)sd_cancelImageLoadOperationWithKey:(nullable NSString *)key; 30 | 31 | /** 32 | * Just remove the operations corresponding to the current UIView and key without cancelling them 33 | * 34 | * @param key key for identifying the operations 35 | */ 36 | - (void)sd_removeImageLoadOperationWithKey:(nullable NSString *)key; 37 | 38 | @end 39 | -------------------------------------------------------------------------------- /Pods/SDWebImage/SDWebImage/UIView+WebCacheOperation.m: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is part of the SDWebImage package. 3 | * (c) Olivier Poitrey 4 | * 5 | * For the full copyright and license information, please view the LICENSE 6 | * file that was distributed with this source code. 7 | */ 8 | 9 | #import "UIView+WebCacheOperation.h" 10 | #import "objc/runtime.h" 11 | 12 | static char loadOperationKey; 13 | 14 | // key is copy, value is weak because operation instance is retained by SDWebImageManager's runningOperations property 15 | // we should use lock to keep thread-safe because these method may not be acessed from main queue 16 | typedef NSMapTable> SDOperationsDictionary; 17 | 18 | @implementation UIView (WebCacheOperation) 19 | 20 | - (SDOperationsDictionary *)sd_operationDictionary { 21 | @synchronized(self) { 22 | SDOperationsDictionary *operations = objc_getAssociatedObject(self, &loadOperationKey); 23 | if (operations) { 24 | return operations; 25 | } 26 | operations = [[NSMapTable alloc] initWithKeyOptions:NSPointerFunctionsStrongMemory valueOptions:NSPointerFunctionsWeakMemory capacity:0]; 27 | objc_setAssociatedObject(self, &loadOperationKey, operations, OBJC_ASSOCIATION_RETAIN_NONATOMIC); 28 | return operations; 29 | } 30 | } 31 | 32 | - (void)sd_setImageLoadOperation:(nullable id)operation forKey:(nullable NSString *)key { 33 | if (key) { 34 | [self sd_cancelImageLoadOperationWithKey:key]; 35 | if (operation) { 36 | SDOperationsDictionary *operationDictionary = [self sd_operationDictionary]; 37 | @synchronized (self) { 38 | [operationDictionary setObject:operation forKey:key]; 39 | } 40 | } 41 | } 42 | } 43 | 44 | - (void)sd_cancelImageLoadOperationWithKey:(nullable NSString *)key { 45 | if (key) { 46 | // Cancel in progress downloader from queue 47 | SDOperationsDictionary *operationDictionary = [self sd_operationDictionary]; 48 | id operation; 49 | 50 | @synchronized (self) { 51 | operation = [operationDictionary objectForKey:key]; 52 | } 53 | if (operation) { 54 | if ([operation conformsToProtocol:@protocol(SDWebImageOperation)]) { 55 | [operation cancel]; 56 | } 57 | @synchronized (self) { 58 | [operationDictionary removeObjectForKey:key]; 59 | } 60 | } 61 | } 62 | } 63 | 64 | - (void)sd_removeImageLoadOperationWithKey:(nullable NSString *)key { 65 | if (key) { 66 | SDOperationsDictionary *operationDictionary = [self sd_operationDictionary]; 67 | @synchronized (self) { 68 | [operationDictionary removeObjectForKey:key]; 69 | } 70 | } 71 | } 72 | 73 | @end 74 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Zhen Tan 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/NSBundle+TZImagePicker.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSBundle+TZImagePicker.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 16/08/18. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface NSBundle (TZImagePicker) 12 | 13 | + (NSBundle *)tz_imagePickerBundle; 14 | 15 | + (NSString *)tz_localizedStringForKey:(NSString *)key value:(NSString *)value; 16 | + (NSString *)tz_localizedStringForKey:(NSString *)key; 17 | 18 | @end 19 | 20 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/NSBundle+TZImagePicker.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSBundle+TZImagePicker.m 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 16/08/18. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import "NSBundle+TZImagePicker.h" 10 | #import "TZImagePickerController.h" 11 | 12 | @implementation NSBundle (TZImagePicker) 13 | 14 | + (NSBundle *)tz_imagePickerBundle { 15 | #ifdef SWIFT_PACKAGE 16 | NSBundle *bundle = SWIFTPM_MODULE_BUNDLE; 17 | #else 18 | NSBundle *bundle = [NSBundle bundleForClass:[TZImagePickerController class]]; 19 | #endif 20 | NSURL *url = [bundle URLForResource:@"TZImagePickerController" withExtension:@"bundle"]; 21 | bundle = [NSBundle bundleWithURL:url]; 22 | return bundle; 23 | } 24 | 25 | + (NSString *)tz_localizedStringForKey:(NSString *)key { 26 | return [self tz_localizedStringForKey:key value:@""]; 27 | } 28 | 29 | + (NSString *)tz_localizedStringForKey:(NSString *)key value:(NSString *)value { 30 | NSBundle *bundle = [TZImagePickerConfig sharedInstance].languageBundle; 31 | NSString *value1 = [bundle localizedStringForKey:key value:value table:nil]; 32 | return value1; 33 | } 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZAssetCell.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | typedef enum : NSUInteger { 13 | TZAssetCellTypePhoto = 0, 14 | TZAssetCellTypeLivePhoto, 15 | TZAssetCellTypePhotoGif, 16 | TZAssetCellTypeVideo, 17 | TZAssetCellTypeAudio, 18 | } TZAssetCellType; 19 | 20 | @class TZAssetModel; 21 | @interface TZAssetCell : UICollectionViewCell 22 | @property (weak, nonatomic) UIButton *selectPhotoButton; 23 | @property (weak, nonatomic) UIButton *cannotSelectLayerButton; 24 | @property (nonatomic, strong) TZAssetModel *model; 25 | @property (assign, nonatomic) NSInteger index; 26 | @property (nonatomic, copy) void (^didSelectPhotoBlock)(BOOL); 27 | @property (nonatomic, assign) TZAssetCellType type; 28 | @property (nonatomic, assign) BOOL allowPickingGif; 29 | @property (nonatomic, assign) BOOL allowPickingMultipleVideo; 30 | @property (nonatomic, copy) NSString *representedAssetIdentifier; 31 | @property (nonatomic, assign) int32_t imageRequestID; 32 | 33 | @property (nonatomic, strong) UIImage *photoSelImage; 34 | @property (nonatomic, strong) UIImage *photoDefImage; 35 | 36 | @property (nonatomic, assign) BOOL showSelectBtn; 37 | @property (assign, nonatomic) BOOL allowPreview; 38 | 39 | @property (nonatomic, copy) void (^assetCellDidSetModelBlock)(TZAssetCell *cell, UIImageView *imageView, UIImageView *selectImageView, UILabel *indexLabel, UIView *bottomView, UILabel *timeLength, UIImageView *videoImgView); 40 | @property (nonatomic, copy) void (^assetCellDidLayoutSubviewsBlock)(TZAssetCell *cell, UIImageView *imageView, UIImageView *selectImageView, UILabel *indexLabel, UIView *bottomView, UILabel *timeLength, UIImageView *videoImgView); 41 | @end 42 | 43 | 44 | @class TZAlbumModel; 45 | @interface TZAlbumCell : UITableViewCell 46 | @property (nonatomic, strong) TZAlbumModel *model; 47 | @property (weak, nonatomic) UIButton *selectedCountButton; 48 | 49 | @property (nonatomic, copy) void (^albumCellDidSetModelBlock)(TZAlbumCell *cell, UIImageView *posterImageView, UILabel *titleLabel); 50 | @property (nonatomic, copy) void (^albumCellDidLayoutSubviewsBlock)(TZAlbumCell *cell, UIImageView *posterImageView, UILabel *titleLabel); 51 | @end 52 | 53 | 54 | @interface TZAssetCameraCell : UICollectionViewCell 55 | @property (nonatomic, strong) UIImageView *imageView; 56 | @end 57 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetModel.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZAssetModel.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | #import 12 | 13 | typedef enum : NSUInteger { 14 | TZAssetModelMediaTypePhoto = 0, 15 | TZAssetModelMediaTypeLivePhoto, 16 | TZAssetModelMediaTypePhotoGif, 17 | TZAssetModelMediaTypeVideo, 18 | TZAssetModelMediaTypeAudio 19 | } TZAssetModelMediaType; 20 | 21 | @class PHAsset; 22 | @interface TZAssetModel : NSObject 23 | 24 | @property (nonatomic, strong) PHAsset *asset; 25 | @property (nonatomic, assign) BOOL isSelected; ///< The select status of a photo, default is No 26 | @property (nonatomic, assign) TZAssetModelMediaType type; 27 | @property (nonatomic, copy) NSString *timeLength; 28 | @property (nonatomic, assign) BOOL iCloudFailed; 29 | 30 | /// Init a photo dataModel With a PHAsset 31 | /// 用一个PHAsset实例,初始化一个照片模型 32 | + (instancetype)modelWithAsset:(PHAsset *)asset type:(TZAssetModelMediaType)type; 33 | + (instancetype)modelWithAsset:(PHAsset *)asset type:(TZAssetModelMediaType)type timeLength:(NSString *)timeLength; 34 | 35 | @end 36 | 37 | 38 | @class PHFetchResult; 39 | @interface TZAlbumModel : NSObject 40 | 41 | @property (nonatomic, strong) NSString *name; ///< The album name 42 | @property (nonatomic, assign) NSInteger count; ///< Count of photos the album contain 43 | @property (nonatomic, strong) PHFetchResult *result; 44 | @property (nonatomic, strong) PHAssetCollection *collection; 45 | @property (nonatomic, strong) PHFetchOptions *options; 46 | 47 | @property (nonatomic, strong) NSArray *models; 48 | @property (nonatomic, strong) NSArray *selectedModels; 49 | @property (nonatomic, assign) NSUInteger selectedCount; 50 | 51 | @property (nonatomic, assign) BOOL isCameraRoll; 52 | 53 | - (void)setResult:(PHFetchResult *)result needFetchAssets:(BOOL)needFetchAssets; 54 | - (void)refreshFetchResult; 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZAssetModel.m: -------------------------------------------------------------------------------- 1 | // 2 | // TZAssetModel.m 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import "TZAssetModel.h" 10 | #import "TZImageManager.h" 11 | 12 | @implementation TZAssetModel 13 | 14 | + (instancetype)modelWithAsset:(PHAsset *)asset type:(TZAssetModelMediaType)type{ 15 | TZAssetModel *model = [[TZAssetModel alloc] init]; 16 | model.asset = asset; 17 | model.isSelected = NO; 18 | model.type = type; 19 | return model; 20 | } 21 | 22 | + (instancetype)modelWithAsset:(PHAsset *)asset type:(TZAssetModelMediaType)type timeLength:(NSString *)timeLength { 23 | TZAssetModel *model = [self modelWithAsset:asset type:type]; 24 | model.timeLength = timeLength; 25 | return model; 26 | } 27 | 28 | @end 29 | 30 | 31 | 32 | @implementation TZAlbumModel 33 | 34 | - (void)setResult:(PHFetchResult *)result needFetchAssets:(BOOL)needFetchAssets { 35 | _result = result; 36 | if (needFetchAssets) { 37 | [[TZImageManager manager] getAssetsFromFetchResult:result completion:^(NSArray *models) { 38 | self->_models = models; 39 | if (self->_selectedModels) { 40 | [self checkSelectedModels]; 41 | } 42 | }]; 43 | } 44 | } 45 | 46 | - (void)refreshFetchResult { 47 | PHFetchResult *fetchResult = [PHAsset fetchAssetsInAssetCollection:self.collection options:self.options]; 48 | self.count = fetchResult.count; 49 | [self setResult:fetchResult]; 50 | } 51 | 52 | - (void)setSelectedModels:(NSArray *)selectedModels { 53 | _selectedModels = selectedModels; 54 | if (_models) { 55 | [self checkSelectedModels]; 56 | } 57 | } 58 | 59 | - (void)checkSelectedModels { 60 | self.selectedCount = 0; 61 | NSMutableSet *selectedAssets = [NSMutableSet setWithCapacity:_selectedModels.count]; 62 | for (TZAssetModel *model in _selectedModels) { 63 | [selectedAssets addObject:model.asset]; 64 | } 65 | for (TZAssetModel *model in _models) { 66 | if ([selectedAssets containsObject:model.asset]) { 67 | self.selectedCount ++; 68 | } 69 | } 70 | } 71 | 72 | - (NSString *)name { 73 | if (_name) { 74 | return _name; 75 | } 76 | return @""; 77 | } 78 | 79 | @end 80 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZGifPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZGifPhotoPreviewController.h 3 | // TZImagePickerController 4 | // 5 | // Created by ttouch on 2016/12/13. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class TZAssetModel; 12 | @interface TZGifPhotoPreviewController : UIViewController 13 | 14 | @property (nonatomic, strong) TZAssetModel *model; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageCropManager.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZImageCropManager.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 2016/12/5. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 图片裁剪管理类 8 | 9 | #import 10 | #import 11 | 12 | @interface TZImageCropManager : NSObject 13 | 14 | /// 裁剪框背景的处理 15 | + (void)overlayClippingWithView:(UIView *)view cropRect:(CGRect)cropRect containerView:(UIView *)containerView needCircleCrop:(BOOL)needCircleCrop; 16 | 17 | /* 18 | 1.7.2 为了解决多位同学对于图片裁剪的需求,我这两天有空便在研究图片裁剪 19 | 幸好有tuyou的PhotoTweaks库做参考,裁剪的功能实现起来简单许多 20 | 该方法和其内部引用的方法基本来自于tuyou的PhotoTweaks库,我做了稍许删减和修改 21 | 感谢tuyou同学在github开源了优秀的裁剪库PhotoTweaks,表示感谢 22 | PhotoTweaks库的github链接:https://github.com/itouch2/PhotoTweaks 23 | */ 24 | /// 获得裁剪后的图片 25 | + (UIImage *)cropImageView:(UIImageView *)imageView toRect:(CGRect)rect zoomScale:(double)zoomScale containerView:(UIView *)containerView; 26 | 27 | /// 获取圆形图片 28 | + (UIImage *)circularClipImage:(UIImage *)image; 29 | 30 | @end 31 | 32 | 33 | /// 该分类的代码来自SDWebImage:https://github.com/rs/SDWebImage 34 | /// 为了防止冲突,我将分类名字和方法名字做了修改 35 | @interface UIImage (TZGif) 36 | 37 | + (UIImage *)sd_tz_animatedGIFWithData:(NSData *)data; 38 | 39 | @end 40 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/MMVideoPreviewPlay@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/MMVideoPreviewPlay@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/MMVideoPreviewPlayHL@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/MMVideoPreviewPlayHL@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/VideoSendIcon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/VideoSendIcon@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ar.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "阿拉伯语"; 2 | "OK" = "حسنا"; 3 | "Back" = "الى الخلف"; 4 | "Done" = "فعله"; 5 | "Edit" = "تعديل"; 6 | "Sorry" = "آسف"; 7 | "Cancel" = "إلغاء"; 8 | "Setting" = "ضبط"; 9 | "Photos" = "الصور"; 10 | "Videos" = "أشرطة فيديو"; 11 | "Preview" = "معاينة"; 12 | "Full image" = "الصورة كاملة"; 13 | "Processing..." = "معالجة..."; 14 | "No Photos or Videos" = "لا توجد صور أو مقاطع فيديو"; 15 | "Synchronizing photos from iCloud" = "مزامنة الصور من iCloud"; 16 | "iCloud sync failed" = "iCloud فشلت المزامنة"; 17 | "Can not use camera" = "لا يمكن استخدام الكاميرا"; 18 | "Can not choose both video and photo" = "لا يمكن اختيار كل من الفيديو والصور"; 19 | "Can not choose both photo and GIF" = "لا يمكن اختيار كل من الصور و GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "حدد مقطع الفيديو عندما يكون في حالة متعددة، وسنعمل على معالجة مقطع الفيديو كصورة"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "إذا تعذّر الانتقال إلى صفحة "إعدادات الخصوصية"، فيرجى الانتقال إلى صفحة "الإعدادات" بنفسك، شكرًا لك"; 22 | "Select a maximum of %zd photos" = "حدد فقط ما يصل إلى %zd صورة"; 23 | "Select a minimum of %zd photos" = "الرجاء تحديد %zd صورة على الأقل"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "السماح لـ %@ بالوصول إلى الألبوم في \"الإعدادات > الخصوصية > الصور\""; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "الرجاء السماح لـ %@ بالوصول إلى الكاميرا في \"الإعدادات > الخصوصية > الكاميرا\""; 26 | "Selected for %ld seconds" = "محدد لمدة %ld ثانية"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/bg.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "保加利亚语"; 2 | "OK" = "Добре"; 3 | "Back" = "обратно"; 4 | "Done" = "Свършен"; 5 | "Edit" = "редактиране"; 6 | "Sorry" = "съжалявам"; 7 | "Cancel" = "Отказ"; 8 | "Setting" = "обстановка"; 9 | "Photos" = "Снимки"; 10 | "Videos" = "Видео"; 11 | "Preview" = "предварителен преглед"; 12 | "Full image" = "Пълно изображение"; 13 | "Processing..." = "Обработка ..."; 14 | "No Photos or Videos" = "Няма снимки или видеоклипове"; 15 | "Synchronizing photos from iCloud" = "Синхронизиране на снимки от iCloud"; 16 | "iCloud sync failed" = "iCloud синхронизирането не бе успешно"; 17 | "Can not use camera" = "Не може да се използва камера"; 18 | "Can not choose both video and photo" = "Не можете да изберете видео и снимка"; 19 | "Can not choose both photo and GIF" = "Не може да се избере снимка и GIF"; 20 | "Selected for %ld seconds" = "Избрано за %ld секунди"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/cs-CZ.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "捷克语"; 2 | "OK" = "OK"; 3 | "Back" = "Zadní"; 4 | "Done" = "Hotovo"; 5 | "Edit" = "Upravit"; 6 | "Sorry" = "Promiňte"; 7 | "Cancel" = "zrušení"; 8 | "Setting" = "Nastavení"; 9 | "Photos" = "Fotky"; 10 | "Videos" = "Videa"; 11 | "Preview" = "Náhled"; 12 | "Full image" = "Celý obrázek"; 13 | "Processing..." = "Zpracovává se..."; 14 | "No Photos or Videos" = "Žádné fotky nebo videa"; 15 | "Synchronizing photos from iCloud" = "Synchronizace fotografií z iCloud"; 16 | "iCloud sync failed" = "iCloud synchronizace selhala"; 17 | "Can not use camera" = "Nelze použít fotoaparát"; 18 | "Can not choose both video and photo" = "Nelze vybrat video ani fotografii"; 19 | "Can not choose both photo and GIF" = "Nelze vybrat fotografie a GIF"; 20 | "Selected for %ld seconds" = "Vybráno na %ld sekund"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/de.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "德语"; 2 | "OK" = "OK"; 3 | "Back" = "Zurück"; 4 | "Done" = "Erledigt"; 5 | "Edit" = "Bearbeiten"; 6 | "Sorry" = "Es tut uns leid"; 7 | "Cancel" = "Stornieren"; 8 | "Setting" = "Rahmen"; 9 | "Photos" = "Fotos"; 10 | "Videos" = "Videos"; 11 | "Preview" = "Vorschau"; 12 | "Full image" = "Vollbild"; 13 | "Processing..." = "Wird bearbeitet..."; 14 | "No Photos or Videos" = "Keine Fotos oder Videos"; 15 | "Synchronizing photos from iCloud" = "Fotos aus iCloud synchronisieren"; 16 | "iCloud sync failed" = "iCloud Synchronisierung fehlgeschlagen"; 17 | "Can not use camera" = "Kann die Kamera nicht benutzen"; 18 | "Can not choose both video and photo" = "Video und Foto können nicht ausgewählt werden"; 19 | "Can not choose both photo and GIF" = "Foto und GIF können nicht ausgewählt werden"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "Wenn Sie das Video im Multi-Status auswählen, wird es als Foto behandelt"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "Sie können nicht zur Seite mit den Datenschutz-Einstellungen springen; bitte navigieren Sie selbst zur Einstellungsseite. Vielen Dank."; 22 | "Select a maximum of %zd photos" = "Wählen Sie maximal %zd Bilder aus"; 23 | "Select a minimum of %zd photos" = "Bitte wählen Sie mindestens %zd Fotos aus"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Erlauben Sie %@ den Zugriff auf Ihr Album unter: „Einstellungen > Datenschutz > Fotos“"; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Erlauben Sie %@ den Zugriff auf Ihre Kamera unter: „Einstellungen > Datenschutz > Kamera“"; 26 | "Selected for %ld seconds" = "Ausgewählt für %ld Sekunden"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/el.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "希腊语"; 2 | "OK" = "Εντάξει"; 3 | "Back" = "Πίσω"; 4 | "Done" = "Εγινε"; 5 | "Edit" = "επεξεργασία"; 6 | "Sorry" = "Συγνώμη"; 7 | "Cancel" = "Ματαίωση"; 8 | "Setting" = "Σύνθεση"; 9 | "Photos" = "Φωτογραφίες"; 10 | "Videos" = "Βίντεο"; 11 | "Preview" = "Προεπισκόπηση"; 12 | "Full image" = "Πλήρης εικόνα"; 13 | "Processing..." = "Επεξεργασία..."; 14 | "No Photos or Videos" = "Δεν υπάρχουν φωτογραφίες ή βίντεο"; 15 | "Synchronizing photos from iCloud" = "Συγχρονισμός φωτογραφιών από το iCloud"; 16 | "iCloud sync failed" = "iCloud Ο συγχρονισμός απέτυχε"; 17 | "Can not use camera" = "Δεν είναι δυνατή η χρήση της κάμερας"; 18 | "Can not choose both video and photo" = "Δεν είναι δυνατή η επιλογή του βίντεο και της φωτογραφίας"; 19 | "Can not choose both photo and GIF" = "Δεν είναι δυνατή η επιλογή φωτογραφίας και GIF"; 20 | "Selected for %ld seconds" = "Selected for %ld seconds"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/en.lproj/Localizable.strings: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/en.lproj/Localizable.strings -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/es.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "西班牙语"; 2 | "OK" = "DE ACUERDO"; 3 | "Back" = "Espalda"; 4 | "Done" = "Hecho"; 5 | "Edit" = "επεξεργασία"; 6 | "Sorry" = "Lo siento"; 7 | "Cancel" = "Cancelar"; 8 | "Setting" = "Ajuste"; 9 | "Photos" = "Las fotos"; 10 | "Videos" = "Videos"; 11 | "Preview" = "Avance"; 12 | "Full image" = "Imagen completa"; 13 | "Processing..." = "Tratamiento..."; 14 | "No Photos or Videos" = "No hay fotos o videos"; 15 | "Synchronizing photos from iCloud" = "Sincronizando fotos desde iCloud"; 16 | "iCloud sync failed" = "la sincronización falló"; 17 | "Can not use camera" = "No puedo usar la camara"; 18 | "Can not choose both video and photo" = "No se puede elegir tanto el video como la foto."; 19 | "Can not choose both photo and GIF" = "No se puede elegir tanto foto como GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "Seleccione el vídeo en estado múltiple, trataremos el vídeo como una fotografía"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "No se puede saltar a la página de ajustes de privacidad, vaya a la página de ajustes manualmente, muchas gracias"; 22 | "Select a maximum of %zd photos" = "Seleccione solamente hasta %zd imágenes"; 23 | "Select a minimum of %zd photos" = "Seleccione al menos %zd fotografías"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Permita que %@ acceda a su galería en \"Ajustes > Privacidad > Fotografías\""; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Permita que %@ acceda a su cámara en \"Ajustes > Privacidad > Cámara\""; 26 | "Selected for %ld seconds" = "Seleccionado para %ld segundos"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/fr.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "法语"; 2 | "OK" = "D'accord"; 3 | "Back" = "Retour"; 4 | "Done" = "Terminé"; 5 | "Edit" = "Éditer"; 6 | "Sorry" = "Pardon"; 7 | "Cancel" = "Annuler"; 8 | "Setting" = "Réglage"; 9 | "Photos" = "Photos"; 10 | "Videos" = "Vidéos"; 11 | "Preview" = "Aperçu"; 12 | "Full image" = "Image complète"; 13 | "Processing..." = "En traitement..."; 14 | "No Photos or Videos" = "Aucune photo ou vidéo"; 15 | "Synchronizing photos from iCloud" = "Synchroniser des photos depuis iCloud"; 16 | "iCloud sync failed" = "iCloud échec de la synchronisation"; 17 | "Can not use camera" = "Impossible d'utiliser la caméra"; 18 | "Can not choose both video and photo" = "Impossible de choisir à la fois la vidéo et la photo"; 19 | "Can not choose both photo and GIF" = "Impossible de choisir à la fois photo et GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "Sélectionnez la vidéo lorsqu’elle est en état multiple, nous la traiterons comme une photo"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "Impossible d'ouvrir la page des paramètres de confidentialité, veuillez accéder vous-même à la page des paramètres, merci"; 22 | "Select a maximum of %zd photos" = "Vous pouvez uniquement sélectionner un maximum de %zd images"; 23 | "Select a minimum of %zd photos" = "Veuillez sélectionner un minimum de %zd photos"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Autorisez %@ à accéder à votre album dans « Paramètres > Confidentialité > Photos »"; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Autorisez %@ à accéder à votre appareil photo dans « Paramètres > Confidentialité > Appareil photo »"; 26 | "Selected for %ld seconds" = "Sélectionné pendant %ld secondes"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/he.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "希伯来语"; 2 | "OK" = "בסדר"; 3 | "Back" = "חזור"; 4 | "Done" = "בוצע"; 5 | "Edit" = "לַעֲרוֹך" 6 | "Sorry" = "מצטער"; 7 | "Cancel" = "בטל"; 8 | "Setting" = "הגדרה"; 9 | "Photos" = "תמונות"; 10 | "Videos" = "סרטונים"; 11 | "Preview" = "תצוגה מקדימה"; 12 | "Full image" = "תמונה מלאה"; 13 | "Processing..." = "מעבד..."; 14 | "No Photos or Videos" = "אין תמונות או סרטונים"; 15 | "Synchronizing photos from iCloud" = "סנכרון תמונות מ - iCloud"; 16 | "iCloud sync failed" = "iCloud הסנכרון נכשל"; 17 | "Can not use camera" = "לא ניתן להשתמש במצלמה"; 18 | "Can not choose both video and photo" = "לא ניתן לבחור הן בסרטון והן בתמונה"; 19 | "Can not choose both photo and GIF" = "לא ניתן לבחור גם תמונה וגם קובץ GIF"; 20 | "Selected for %ld seconds" = "נבחר למשך %ld שניות"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/iCloudError@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/iCloudError@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/it.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "意大利语"; 2 | "OK" = "ok"; 3 | "Back" = "Indietro"; 4 | "Done" = "Fatto"; 5 | "Edit" = "modificare"; 6 | "Sorry" = "scusate"; 7 | "Cancel" = "Annulla"; 8 | "Setting" = "Ambientazione"; 9 | "Photos" = "Fotografie"; 10 | "Videos" = "video"; 11 | "Preview" = "Anteprima"; 12 | "Full image" = "Immagine completa"; 13 | "Processing..." = "In lavorazione..."; 14 | "No Photos or Videos" = "Nessuna foto o video"; 15 | "Synchronizing photos from iCloud" = "Sincronizzazione delle foto da iCloud"; 16 | "iCloud sync failed" = "iCloud sincronizzazione non riuscita"; 17 | "Can not use camera" = "Non è possibile utilizzare la fotocamera"; 18 | "Can not choose both video and photo" = "Non è possibile scegliere sia video che foto"; 19 | "Can not choose both photo and GIF" = "Non è possibile scegliere sia foto che GIF"; 20 | "Selected for %ld seconds" = "Selezionato per %ld secondi"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ja.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "日语"; 2 | "OK" = "OK"; 3 | "Back" = "バック"; 4 | "Done" = "完了"; 5 | "Edit" = "編集する"; 6 | "Sorry" = "ごめんなさい"; 7 | "Cancel" = "キャンセル"; 8 | "Setting" = "設定"; 9 | "Photos" = "写真"; 10 | "Videos" = "動画"; 11 | "Preview" = "プレビュー"; 12 | "Full image" = "フルイメージ"; 13 | "Processing..." = "処理..."; 14 | "No Photos or Videos" = "写真やビデオはありません"; 15 | "Synchronizing photos from iCloud" = "iCloudから写真を同期する"; 16 | "iCloud sync failed" = "iCloud同期に失敗しました"; 17 | "Can not use camera" = "カメラが使えない"; 18 | "Can not choose both video and photo" = "ビデオと写真の両方を選択することはできません"; 19 | "Can not choose both photo and GIF" = "写真とGIFの両方を選択することはできません"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "多肢選択の状態で、ビデオを選択すると、ビデオをデフォルトに画像として送信します。"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "プライバシー設定画面にジャンプできません。手動で設定画面を表示してください。"; 22 | "Select a maximum of %zd photos" = "写真は多くとも%zd 枚選択できます。"; 23 | "Select a minimum of %zd photos" = "少なくとも %zd 枚の写真を選択してください。"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "iPhoneの「設定-プライバシー-写真」のオプションで、r%@の携帯電話のアルバムへのアクセス権限を許可してください。"; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "iPhoneの「設定-プライバシー-カメラ」で、%@のカメラへのアクセス権限を許可してください。"; 26 | "Selected for %ld seconds" = "%ld 秒間選択されました"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ko-KP.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "朝鲜语"; 2 | "OK" = "그래"; 3 | "Back" = "뒤로"; 4 | "Done" = "완료"; 5 | "Edit" = "편집하다"; 6 | "Sorry" = "미안해요"; 7 | "Cancel" = "취소"; 8 | "Setting" = "설정"; 9 | "Photos" = "사진"; 10 | "Videos" = "동영상"; 11 | "Preview" = "미리 보기"; 12 | "Full image" = "전체 이미지"; 13 | "Processing..." = "처리..."; 14 | "No Photos or Videos" = "아무 사진이 나 동영상"; 15 | "Synchronizing photos from iCloud" = "ICloud에서 사진을 동기화"; 16 | "iCloud sync failed" = "iCloud동기화 실패"; 17 | "Can not use camera" = "카메라를 사용할 수 없습니다."; 18 | "Can not choose both video and photo" = "비디오와 사진 둘 다를 선택할 수 없습니다."; 19 | "Can not choose both photo and GIF" = "사진 및 GIF를 선택할 수 없습니다."; 20 | "Select the video when in multi state, we will handle the video as a photo" = "다중 선택 모드에서 비디오를 선택하면 비디오를 사진으로 처리합니다."; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "개인 정보 보호 설정 페이지로 바로 이동할 수 없습니다. 설정 페이지로 직접 이동해 주세요. 감사합니다."; 22 | "Select a maximum of %zd photos" = "최대 %zd장의 이미지만 선택할 수 있습니다."; 23 | "Select a minimum of %zd photos" = "최소 %zd장의 사진을 선택해 주세요."; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "\"설정 > 개인 정보 보호 > 사진\"에서 %@이(가) 앨범에 접근할 수 있도록 허용하세요."; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "\"설정 > 개인 정보 보호 > 카메라\"에서 %@이(가) 카메라에 접근할 수 있도록 허용하세요."; 26 | "Selected for %ld seconds" = "%ld 초 동안 선택됨"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ko.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "韩语"; 2 | "OK" = "승인"; 3 | "Back" = "뒤로"; 4 | "Done" = "끝난"; 5 | "Edit" = "편집하다"; 6 | "Sorry" = "죄송합니다"; 7 | "Cancel" = "취소"; 8 | "Setting" = "환경"; 9 | "Photos" = "사진들"; 10 | "Videos" = "비디오"; 11 | "Preview" = "시사"; 12 | "Full image" = "전체 이미지"; 13 | "Processing..." = "처리 중 ..."; 14 | "No Photos or Videos" = "사진이나 동영상 없음"; 15 | "Synchronizing photos from iCloud" = "iCloud에서 사진 동기화"; 16 | "iCloud sync failed" = "iCloud동기화 실패"; 17 | "Can not use camera" = "카메라를 사용할 수 없습니다."; 18 | "Can not choose both video and photo" = "동영상과 사진을 모두 선택할 수 없습니다."; 19 | "Can not choose both photo and GIF" = "사진과 GIF를 모두 선택할 수 없습니다."; 20 | "Selected for %ld seconds" = "%ld 초 동안 선택됨"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/navi_back@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/navi_back@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/nl.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "荷兰语"; 2 | "OK" = "OK"; 3 | "Back" = "Terug"; 4 | "Done" = "Gedaan"; 5 | "Edit" = "Bewerk"; 6 | "Sorry" = "Sorry"; 7 | "Cancel" = "annuleren"; 8 | "Setting" = "omgeving"; 9 | "Photos" = "foto's"; 10 | "Videos" = "Videos"; 11 | "Preview" = "Voorbeeld"; 12 | "Full image" = "Volledig beeld"; 13 | "Processing..." = "Verwerken..."; 14 | "No Photos or Videos" = "Geen foto's of video's"; 15 | "Synchronizing photos from iCloud" = "Foto's synchroniseren vanuit iCloud"; 16 | "iCloud sync failed" = "iCloud synchronisatie is mislukt"; 17 | "Can not use camera" = "Kan de camera niet gebruiken"; 18 | "Can not choose both video and photo" = "Kan niet zowel video als foto kiezen"; 19 | "Can not choose both photo and GIF" = "Kan niet zowel foto als GIF kiezen"; 20 | "Selected for %ld seconds" = "Geselecteerd voor %ld seconden"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_def_photoPickerVc@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_def_photoPickerVc@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_def_previewVc@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_def_previewVc@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_number_icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_number_icon@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_original_def@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_original_def@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_original_sel@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_original_sel@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_sel_photoPickerVc@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_sel_photoPickerVc@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_sel_previewVc@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/photo_sel_previewVc@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/pl.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "波兰语"; 2 | "OK" = "dobrze"; 3 | "Back" = "Z powrotem"; 4 | "Done" = "Gotowe"; 5 | "Edit" = "edytować"; 6 | "Sorry" = "Przepraszam"; 7 | "Cancel" = "Anuluj"; 8 | "Setting" = "Oprawa"; 9 | "Photos" = "Zdjęcia"; 10 | "Videos" = "Filmy"; 11 | "Preview" = "Zapowiedź"; 12 | "Full image" = "Pełny obraz"; 13 | "Processing..." = "Przetwarzanie..."; 14 | "No Photos or Videos" = "Brak zdjęć lub filmów"; 15 | "Synchronizing photos from iCloud" = "Synchronizowanie zdjęć z iCloud"; 16 | "iCloud sync failed" = "iCloud synchronizacja nie powiodła się"; 17 | "Can not use camera" = "Nie można używać aparatu"; 18 | "Can not choose both video and photo" = "Nie można wybrać zarówno wideo,jak i zdjęcia"; 19 | "Can not choose both photo and GIF" = "Nie można wybrać zarówno zdjęcia,jak i GIF"; 20 | "Selected for %ld seconds" = "Wybrany przez %ld sekund"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/preview_number_icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/preview_number_icon@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/preview_original_def@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/preview_original_def@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/pt.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "葡萄牙语"; 2 | "OK" = "Está bem"; 3 | "Back" = "De volta"; 4 | "Done" = "Feito"; 5 | "Edit" = "editar"; 6 | "Sorry" = "Desculpa"; 7 | "Cancel" = "Cancelar"; 8 | "Setting" = "Configuração"; 9 | "Photos" = "Fotos"; 10 | "Videos" = "Vídeos"; 11 | "Preview" = "Visualizar"; 12 | "Full image" = "Imagem Completa"; 13 | "Processing..." = "Em processamento..."; 14 | "No Photos or Videos" = "Sem fotos ou vídeos"; 15 | "Synchronizing photos from iCloud" = "Sincronizando fotos do iCloud"; 16 | "iCloud sync failed" = "iCloud falha na sincronização"; 17 | "Can not use camera" = "Não pode usar a câmera"; 18 | "Can not choose both video and photo" = "Não é possível escolher vídeo e foto"; 19 | "Can not choose both photo and GIF" = "Não é possível escolher foto e GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "Se estiver em estado múltiplo, selecione a opção vídeo; iremos utilizar o vídeo como uma foto"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "Não é possível avançar para a página de definições de privacidade, aceda à página de definições você mesmo, obrigado"; 22 | "Select a maximum of %zd photos" = "Selecione apenas %zd imagens,no máximo"; 23 | "Select a minimum of %zd photos" = "Selecione %zd fotos,no mínimo"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Permita a %@ aceder ao seu álbum em “Definições > Privacidade > Fotos”"; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Permita a %@ aceder à sua câmara em “Definições > Privacidade > Câmara”"; 26 | "Selected for %ld seconds" = "Selecionado por %ld segundos"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ro.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "罗马尼亚语"; 2 | "OK" = "O.K"; 3 | "Back" = "Înapoi"; 4 | "Done" = "Terminat"; 5 | "Edit" = "Editați | ×"; 6 | "Sorry" = "scuze"; 7 | "Cancel" = "Anulare"; 8 | "Setting" = "reglaj"; 9 | "Photos" = "Fotografii"; 10 | "Videos" = "Videoclipuri"; 11 | "Preview" = "previzualizare"; 12 | "Full image" = "Imagine completă"; 13 | "Processing..." = "Prelucrare..."; 14 | "No Photos or Videos" = "Nu există fotografii sau videoclipuri"; 15 | "Synchronizing photos from iCloud" = "Sincronizarea fotografiilor cu iCloud"; 16 | "iCloud sync failed" = "iCloud sincronizarea a eșuat"; 17 | "Can not use camera" = "Nu pot folosi camera"; 18 | "Can not choose both video and photo" = "Nu puteți alege atât videoclipul,cât și fotografia"; 19 | "Can not choose both photo and GIF" = "Nu puteți alege atât fotografia,cât și GIF"; 20 | "Selected for %ld seconds" = "Selectat pentru %ld secunde"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/ru.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "俄语"; 2 | "OK" = "Хорошо"; 3 | "Back" = "назад"; 4 | "Done" = "Готово"; 5 | "Edit" = "редактировать"; 6 | "Sorry" = "сожалею"; 7 | "Cancel" = "отменить"; 8 | "Setting" = "настройка"; 9 | "Photos" = "Фото"; 10 | "Videos" = "Видео"; 11 | "Preview" = "предварительный просмотр"; 12 | "Full image" = "Полное изображение"; 13 | "Processing..." = "Обработка ..."; 14 | "No Photos or Videos" = "Нет фото или видео"; 15 | "Synchronizing photos from iCloud" = "Синхронизация фотографий из iCloud"; 16 | "iCloud sync failed" = "iCloud сбой синхронизации"; 17 | "Can not use camera" = "Не могу использовать камеру"; 18 | "Can not choose both video and photo" = "Не могу выбрать как видео,так и фото"; 19 | "Can not choose both photo and GIF" = "Не могу выбрать фото и GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "В случае выбора видео при нахождении в мультирежиме видео будет обработано как фотография"; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "Не удается перейти на страницу настроек конфиденциальности. Перейдите на эту страницу самостоятельно"; 22 | "Select a maximum of %zd photos" = "Вы можете выбрать до %zd изображений"; 23 | "Select a minimum of %zd photos" = "Вы можете выбрать не менее %zd изображений"; 24 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Разрешите доступ %@ к вашему альбому,перейдя в Настройки > Конфиденциальность > Фото"; 25 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Разрешите доступ %@ к камере вашего устройства,перейдя в Настройки > Конфиденциальность > Камера"; 26 | "Selected for %ld seconds" = "Выбрано для %ld секунд"; 27 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/sk.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "斯洛伐克语"; 2 | "OK" = "OK"; 3 | "Back" = "späť"; 4 | "Done" = "hotový"; 5 | "Edit" = "upraviť"; 6 | "Sorry" = "Prepáč"; 7 | "Cancel" = "Zrušiť"; 8 | "Setting" = "nastavenie"; 9 | "Photos" = "fotografie"; 10 | "Videos" = "videá"; 11 | "Preview" = "Náhľad"; 12 | "Full image" = "Celý obrázok"; 13 | "Processing..." = "Spracovanie ..."; 14 | "No Photos or Videos" = "Žiadne fotografie alebo videá"; 15 | "Synchronizing photos from iCloud" = "Synchronizácia fotografií z iCloud"; 16 | "iCloud sync failed" = "iCloud synchronizácia zlyhala"; 17 | "Can not use camera" = "Fotoaparát nie je možné používať"; 18 | "Can not choose both video and photo" = "Nie je možné vybrať video aj fotografiu"; 19 | "Can not choose both photo and GIF" = "Nie je možné vybrať fotografie a obrázky GIF"; 20 | "Selected for %ld seconds" = "Vybraté na %ld sekundy"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/sv.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "瑞典语"; 2 | "OK" = "ok"; 3 | "Back" = "Tillbaka"; 4 | "Done" = "Gjort"; 5 | "Edit" = "redigera"; 6 | "Sorry" = "Förlåt"; 7 | "Cancel" = "Annullera"; 8 | "Setting" = "Miljö"; 9 | "Photos" = "foton"; 10 | "Videos" = "videoklipp"; 11 | "Preview" = "Förhandsvisning"; 12 | "Full image" = "Fullbild"; 13 | "Processing..." = "Bearbetning ..."; 14 | "No Photos or Videos" = "Inga foton eller videor"; 15 | "Synchronizing photos from iCloud" = "Synkronisera foton från iCloud"; 16 | "iCloud sync failed" = "iCloud synkroniseringen misslyckades"; 17 | "Can not use camera" = "Kan inte använda kamera"; 18 | "Can not choose both video and photo" = "Kan inte välja både video och foto"; 19 | "Can not choose both photo and GIF" = "Kan inte välja både foto och GIF"; 20 | "Selected for %ld seconds" = "Vald för %ld sekunder"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/takePicture80@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/takePicture80@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/takePicture@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/takePicture@2x.png -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/th.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "泰语"; 2 | "OK" = "ตกลง"; 3 | "Back" = "กลับ"; 4 | "Done" = "เสร็จสิ้น"; 5 | "Edit" = "แก้ไข"; 6 | "Sorry" = "ขอโทษ"; 7 | "Cancel" = "ยกเลิก"; 8 | "Setting" = "การตั้งค่า"; 9 | "Photos" = "ภาพถ่าย"; 10 | "Videos" = "วิดีโอ"; 11 | "Preview" = "ดูตัวอย่าง"; 12 | "Full image" = "ภาพเต็ม"; 13 | "Processing..." = "กำลังประมวลผล ..."; 14 | "No Photos or Videos" = "ไม่มีรูปภาพหรือวิดีโอ"; 15 | "Synchronizing photos from iCloud" = "การซิงโครไนซ์ภาพถ่ายจาก iCloud"; 16 | "iCloud sync failed" = "iCloud การซิงค์ล้มเหลว"; 17 | "Can not use camera" = "ไม่สามารถใช้กล้องถ่ายรูป"; 18 | "Can not choose both video and photo" = "ไม่สามารถเลือกได้ทั้งวิดีโอและภาพถ่าย"; 19 | "Can not choose both photo and GIF" = "ไม่สามารถเลือกได้ทั้งภาพถ่ายและ GIF"; 20 | "Selected for %ld seconds" = "เลือกไว้เป็นเวลา %ld วินาที"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/tr.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "土耳其语"; 2 | "OK" = "tamam"; 3 | "Back" = "Geri"; 4 | "Done" = "tamam"; 5 | "Edit" = "Düzenle"; 6 | "Sorry" = "Afedersiniz"; 7 | "Cancel" = "İptal etmek"; 8 | "Setting" = "Ayar"; 9 | "Photos" = "Fotoğraflar"; 10 | "Videos" = "Videolar"; 11 | "Preview" = "Ön izleme"; 12 | "Full image" = "Tam görüntü"; 13 | "Processing..." = "İşleme..."; 14 | "No Photos or Videos" = "Fotoğraf veya Video Yok"; 15 | "Synchronizing photos from iCloud" = "Fotoğrafları iCloud'dan senkronize etme"; 16 | "iCloud sync failed" = "iCloud senkronizasyon başarısız oldu"; 17 | "Can not use camera" = "Kamera kullanılamaz"; 18 | "Can not choose both video and photo" = "Hem video hem de fotoğraf seçilemiyor"; 19 | "Can not choose both photo and GIF" = "Hem fotoğraf hem de GIF seçilemiyor"; 20 | "Selected for %ld seconds" = "%ld saniye için seçildi"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/uk.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "乌克兰语"; 2 | "OK" = "в порядку"; 3 | "Back" = "Назад"; 4 | "Done" = "Виконано"; 5 | "Edit" = "редагувати"; 6 | "Sorry" = "Вибачте"; 7 | "Cancel" = "Скасувати"; 8 | "Setting" = "Налаштування"; 9 | "Photos" = "Фотографії"; 10 | "Videos" = "Відео"; 11 | "Preview" = "Попередній перегляд"; 12 | "Full image" = "Повне зображення"; 13 | "Processing..." = "Обробка ..."; 14 | "No Photos or Videos" = "Немає фотографій або відео"; 15 | "Synchronizing photos from iCloud" = "Синхронізація фотографій з iCloud"; 16 | "iCloud sync failed" = "iCloud помилка синхронізації"; 17 | "Can not use camera" = "Не можна використовувати камеру"; 18 | "Can not choose both video and photo" = "Неможливо вибрати як відео,так і фото"; 19 | "Can not choose both photo and GIF" = "Неможливо вибрати як фото,так і GIF"; 20 | "Selected for %ld seconds" = "Đã chọn cho %ld giây"; 21 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/vi.lproj/Localizable.strings: -------------------------------------------------------------------------------- 1 | "KEY" = "越南语"; 2 | "OK" = "Xác nhận"; 3 | "Back" = "Quay lại"; 4 | "Done" = "Hoàn thành"; 5 | "Edit" = "biên tập"; 6 | "Sorry" = "Xin lỗi"; 7 | "Cancel" = "Hủy"; 8 | "Setting" = "Cài đặt"; 9 | "Photos" = "Hình"; 10 | "Videos" = "Clip"; 11 | "Preview" = "Xem trước"; 12 | "Full image" = "Hình gốc"; 13 | "Processing..." = "Đang xử lý..."; 14 | "No Photos or Videos" = "Không có ảnh hoặc video"; 15 | "Can not use camera" = "Máy chụp hình không khả dụng"; 16 | "Synchronizing photos from iCloud" = "Đang đồng bộ hình ảnh từ ICloud"; 17 | "iCloud sync failed" = "iCloud đồng bộ hóa không thành công"; 18 | "Can not choose both video and photo" = "Trong lúc chọn hình ảnh không cùng lúc chọn video"; 19 | "Can not choose both photo and GIF" = "Trong lúc chọn hình ảnh không cùng lúc chọn hình GIF"; 20 | "Select the video when in multi state, we will handle the video as a photo" = "Chọn hình ảnh cùng video, video sẽ bị mặc nhận thành hình ảnh và gửi đi."; 21 | "Can not jump to the privacy settings page, please go to the settings page by self, thank you" = "Không thể chuyển tự động qua trang cài đặt riêng tư, bạn hãy thoát ra cà điều chỉnh lại, cám ơn bạn."; 22 | 23 | "Select a maximum of %zd photos" = "Bạn chỉ được chọn nhiều nhất %zd tấm hình"; 24 | "Select a minimum of %zd photos" = "Chọn ít nhất %zd tấm hình"; 25 | "Allow %@ to access your album in \"Settings -> Privacy -> Photos\"" = "Vui lòng tại mục iPhone \" Cài đặt – quyền riêng tư - Ảnh\" mở quyền cho phép %@ truy cập ảnh."; 26 | "Please allow %@ to access your camera in \"Settings -> Privacy -> Camera\"" = "Vui lòng tại mục iPhone \" Cài đặt – quyền riêng tư - Ảnh\" mở quyền cho phép %@ truy cập máy ảnh"; 27 | "Selected for %ld seconds" = "Đã chọn cho %ld giây"; 28 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/zh-Hans.lproj/Localizable.strings: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/zh-Hans.lproj/Localizable.strings -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/zh-Hant.lproj/Localizable.strings: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle/zh-Hant.lproj/Localizable.strings -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageRequestOperation.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZImageRequestOperation.h 3 | // TZImagePickerControllerFramework 4 | // 5 | // Created by 谭真 on 2018/12/20. 6 | // Copyright © 2018 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | NS_ASSUME_NONNULL_BEGIN 13 | 14 | @interface TZImageRequestOperation : NSOperation 15 | 16 | typedef void(^TZImageRequestCompletedBlock)(UIImage *photo, NSDictionary *info, BOOL isDegraded); 17 | typedef void(^TZImageRequestProgressBlock)(double progress, NSError *error, BOOL *stop, NSDictionary *info); 18 | 19 | @property (nonatomic, copy, nullable) TZImageRequestCompletedBlock completedBlock; 20 | @property (nonatomic, copy, nullable) TZImageRequestProgressBlock progressBlock; 21 | @property (nonatomic, strong, nullable) PHAsset *asset; 22 | 23 | @property (assign, nonatomic, getter = isExecuting) BOOL executing; 24 | @property (assign, nonatomic, getter = isFinished) BOOL finished; 25 | 26 | - (instancetype)initWithAsset:(PHAsset *)asset completion:(TZImageRequestCompletedBlock)completionBlock progressHandler:(TZImageRequestProgressBlock)progressHandler; 27 | - (void)done; 28 | @end 29 | 30 | NS_ASSUME_NONNULL_END 31 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImageRequestOperation.m: -------------------------------------------------------------------------------- 1 | // 2 | // TZImageRequestOperation.m 3 | // TZImagePickerControllerFramework 4 | // 5 | // Created by 谭真 on 2018/12/20. 6 | // Copyright © 2018 谭真. All rights reserved. 7 | // 8 | 9 | #import "TZImageRequestOperation.h" 10 | #import "TZImageManager.h" 11 | 12 | @implementation TZImageRequestOperation 13 | 14 | @synthesize executing = _executing; 15 | @synthesize finished = _finished; 16 | 17 | - (instancetype)initWithAsset:(PHAsset *)asset completion:(TZImageRequestCompletedBlock)completionBlock progressHandler:(TZImageRequestProgressBlock)progressHandler { 18 | self = [super init]; 19 | self.asset = asset; 20 | self.completedBlock = completionBlock; 21 | self.progressBlock = progressHandler; 22 | _executing = NO; 23 | _finished = NO; 24 | return self; 25 | } 26 | 27 | - (void)start { 28 | self.executing = YES; 29 | [[TZImageManager manager] getPhotoWithAsset:self.asset completion:^(UIImage *photo, NSDictionary *info, BOOL isDegraded) { 30 | dispatch_async(dispatch_get_main_queue(), ^{ 31 | if (!isDegraded) { 32 | if (self.completedBlock) { 33 | self.completedBlock(photo, info, isDegraded); 34 | } 35 | dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.1 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ 36 | [self done]; 37 | }); 38 | } 39 | }); 40 | } progressHandler:^(double progress, NSError *error, BOOL *stop, NSDictionary *info) { 41 | dispatch_async(dispatch_get_main_queue(), ^{ 42 | if (self.progressBlock) { 43 | self.progressBlock(progress, error, stop, info); 44 | } 45 | }); 46 | } networkAccessAllowed:YES]; 47 | } 48 | 49 | - (void)done { 50 | self.finished = YES; 51 | self.executing = NO; 52 | [self reset]; 53 | } 54 | 55 | - (void)reset { 56 | self.asset = nil; 57 | self.completedBlock = nil; 58 | self.progressBlock = nil; 59 | } 60 | 61 | - (void)setFinished:(BOOL)finished { 62 | [self willChangeValueForKey:@"isFinished"]; 63 | _finished = finished; 64 | [self didChangeValueForKey:@"isFinished"]; 65 | } 66 | 67 | - (void)setExecuting:(BOOL)executing { 68 | [self willChangeValueForKey:@"isExecuting"]; 69 | _executing = executing; 70 | [self didChangeValueForKey:@"isExecuting"]; 71 | } 72 | 73 | - (BOOL)isAsynchronous { 74 | return YES; 75 | } 76 | 77 | @end 78 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZLocationManager.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZLocationManager.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 2017/06/03. 6 | // Copyright © 2017年 谭真. All rights reserved. 7 | // 定位管理类 8 | 9 | 10 | #import 11 | #import 12 | 13 | @interface TZLocationManager : NSObject 14 | 15 | + (instancetype)manager NS_SWIFT_NAME(default()); 16 | 17 | /// 开始定位 18 | - (void)startLocation; 19 | - (void)startLocationWithSuccessBlock:(void (^)(NSArray *))successBlock failureBlock:(void (^)(NSError *error))failureBlock; 20 | - (void)startLocationWithGeocoderBlock:(void (^)(NSArray *geocoderArray))geocoderBlock; 21 | - (void)startLocationWithSuccessBlock:(void (^)(NSArray *))successBlock failureBlock:(void (^)(NSError *error))failureBlock geocoderBlock:(void (^)(NSArray *geocoderArray))geocoderBlock; 22 | 23 | /// 结束定位 24 | - (void)stopUpdatingLocation; 25 | 26 | @end 27 | 28 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZLocationManager.m: -------------------------------------------------------------------------------- 1 | // 2 | // TZLocationManager.m 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 2017/06/03. 6 | // Copyright © 2017年 谭真. All rights reserved. 7 | // 定位管理类 8 | 9 | #import "TZLocationManager.h" 10 | #import "TZImagePickerController.h" 11 | 12 | @interface TZLocationManager () 13 | @property (nonatomic, strong) CLLocationManager *locationManager; 14 | /// 定位成功的回调block 15 | @property (nonatomic, copy) void (^successBlock)(NSArray *); 16 | /// 编码成功的回调block 17 | @property (nonatomic, copy) void (^geocodeBlock)(NSArray *geocodeArray); 18 | /// 定位失败的回调block 19 | @property (nonatomic, copy) void (^failureBlock)(NSError *error); 20 | @end 21 | 22 | @implementation TZLocationManager 23 | 24 | + (instancetype)manager { 25 | static TZLocationManager *manager; 26 | static dispatch_once_t onceToken; 27 | dispatch_once(&onceToken, ^{ 28 | manager = [[self alloc] init]; 29 | manager.locationManager = [[CLLocationManager alloc] init]; 30 | manager.locationManager.delegate = manager; 31 | [manager.locationManager requestWhenInUseAuthorization]; 32 | }); 33 | return manager; 34 | } 35 | 36 | - (void)startLocation { 37 | [self startLocationWithSuccessBlock:nil failureBlock:nil geocoderBlock:nil]; 38 | } 39 | 40 | - (void)startLocationWithSuccessBlock:(void (^)(NSArray *))successBlock failureBlock:(void (^)(NSError *error))failureBlock { 41 | [self startLocationWithSuccessBlock:successBlock failureBlock:failureBlock geocoderBlock:nil]; 42 | } 43 | 44 | - (void)startLocationWithGeocoderBlock:(void (^)(NSArray *geocoderArray))geocoderBlock { 45 | [self startLocationWithSuccessBlock:nil failureBlock:nil geocoderBlock:geocoderBlock]; 46 | } 47 | 48 | - (void)startLocationWithSuccessBlock:(void (^)(NSArray *))successBlock failureBlock:(void (^)(NSError *error))failureBlock geocoderBlock:(void (^)(NSArray *geocoderArray))geocoderBlock { 49 | [self.locationManager startUpdatingLocation]; 50 | _successBlock = successBlock; 51 | _geocodeBlock = geocoderBlock; 52 | _failureBlock = failureBlock; 53 | } 54 | 55 | - (void)stopUpdatingLocation { 56 | [self.locationManager stopUpdatingLocation]; 57 | } 58 | 59 | #pragma mark - CLLocationManagerDelegate 60 | 61 | /// 地理位置发生改变时触发 62 | - (void)locationManager:(CLLocationManager *)manager didUpdateLocations:(NSArray *)locations { 63 | [manager stopUpdatingLocation]; 64 | 65 | if (_successBlock) { 66 | _successBlock(locations); 67 | } 68 | 69 | if (_geocodeBlock && locations.count) { 70 | CLGeocoder *geocoder = [[CLGeocoder alloc] init]; 71 | [geocoder reverseGeocodeLocation:[locations firstObject] completionHandler:^(NSArray *array, NSError *error) { 72 | self->_geocodeBlock(array); 73 | }]; 74 | } 75 | } 76 | 77 | /// 定位失败回调方法 78 | - (void)locationManager:(CLLocationManager *)manager didFailWithError:(NSError *)error { 79 | NSLog(@"定位失败, 错误: %@",error); 80 | switch([error code]) { 81 | case kCLErrorDenied: { // 用户禁止了定位权限 82 | 83 | } break; 84 | default: break; 85 | } 86 | if (_failureBlock) { 87 | _failureBlock(error); 88 | } 89 | } 90 | 91 | @end 92 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPickerController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZPhotoPickerController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class TZAlbumModel; 12 | @interface TZPhotoPickerController : UIViewController 13 | 14 | @property (nonatomic, assign) BOOL isFirstAppear; 15 | @property (nonatomic, assign) NSInteger columnNumber; 16 | @property (nonatomic, strong) TZAlbumModel *model; 17 | @end 18 | 19 | 20 | @interface TZCollectionView : UICollectionView 21 | 22 | @end 23 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZPhotoPreviewCell.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class TZAssetModel; 12 | @interface TZAssetPreviewCell : UICollectionViewCell 13 | @property (nonatomic, strong) TZAssetModel *model; 14 | @property (nonatomic, copy) void (^singleTapGestureBlock)(void); 15 | - (void)configSubviews; 16 | - (void)photoPreviewCollectionViewDidScroll; 17 | @end 18 | 19 | 20 | @class TZAssetModel,TZProgressView,TZPhotoPreviewView; 21 | @interface TZPhotoPreviewCell : TZAssetPreviewCell 22 | 23 | @property (nonatomic, copy) void (^imageProgressUpdateBlock)(double progress); 24 | 25 | @property (nonatomic, strong) TZPhotoPreviewView *previewView; 26 | 27 | @property (nonatomic, assign) BOOL allowCrop; 28 | @property (nonatomic, assign) CGRect cropRect; 29 | @property (nonatomic, assign) BOOL scaleAspectFillCrop; 30 | 31 | - (void)recoverSubviews; 32 | 33 | @end 34 | 35 | 36 | @interface TZPhotoPreviewView : UIView 37 | @property (nonatomic, strong) UIImageView *imageView; 38 | @property (nonatomic, strong) UIScrollView *scrollView; 39 | @property (nonatomic, strong) UIView *imageContainerView; 40 | @property (nonatomic, strong) TZProgressView *progressView; 41 | @property (nonatomic, strong) UIImageView *iCloudErrorIcon; 42 | @property (nonatomic, strong) UILabel *iCloudErrorLabel; 43 | @property (nonatomic, copy) void (^iCloudSyncFailedHandle)(id asset, BOOL isSyncFailed); 44 | 45 | 46 | @property (nonatomic, assign) BOOL allowCrop; 47 | @property (nonatomic, assign) CGRect cropRect; 48 | @property (nonatomic, assign) BOOL scaleAspectFillCrop; 49 | @property (nonatomic, strong) TZAssetModel *model; 50 | @property (nonatomic, strong) id asset; 51 | @property (nonatomic, copy) void (^singleTapGestureBlock)(void); 52 | @property (nonatomic, copy) void (^imageProgressUpdateBlock)(double progress); 53 | 54 | @property (nonatomic, assign) int32_t imageRequestID; 55 | 56 | - (void)recoverSubviews; 57 | @end 58 | 59 | 60 | @class AVPlayer, AVPlayerLayer; 61 | @interface TZVideoPreviewCell : TZAssetPreviewCell 62 | @property (strong, nonatomic) AVPlayer *player; 63 | @property (strong, nonatomic) AVPlayerLayer *playerLayer; 64 | @property (strong, nonatomic) UIButton *playButton; 65 | @property (strong, nonatomic) UIImage *cover; 66 | @property (nonatomic, strong) NSURL *videoURL; 67 | @property (nonatomic, strong) UIImageView *iCloudErrorIcon; 68 | @property (nonatomic, strong) UILabel *iCloudErrorLabel; 69 | @property (nonatomic, copy) void (^iCloudSyncFailedHandle)(id asset, BOOL isSyncFailed); 70 | - (void)pausePlayerAndShowNaviBar; 71 | @end 72 | 73 | 74 | @interface TZGifPreviewCell : TZAssetPreviewCell 75 | @property (strong, nonatomic) TZPhotoPreviewView *previewView; 76 | @end 77 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZPhotoPreviewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZPhotoPreviewController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TZPhotoPreviewController : UIViewController 12 | 13 | @property (nonatomic, strong) NSMutableArray *models; ///< All photo models / 所有图片模型数组 14 | @property (nonatomic, strong) NSMutableArray *photos; ///< All photos / 所有图片数组 15 | @property (nonatomic, assign) NSInteger currentIndex; ///< Index of the photo user click / 用户点击的图片的索引 16 | @property (nonatomic, assign) BOOL isSelectOriginalPhoto; ///< If YES,return original photo / 是否返回原图 17 | @property (nonatomic, assign) BOOL isCropImage; 18 | 19 | /// Return the new selected photos / 返回最新的选中图片数组 20 | @property (nonatomic, copy) void (^backButtonClickBlock)(BOOL isSelectOriginalPhoto); 21 | @property (nonatomic, copy) void (^doneButtonClickBlock)(BOOL isSelectOriginalPhoto); 22 | @property (nonatomic, copy) void (^doneButtonClickBlockCropMode)(UIImage *cropedImage,id asset); 23 | @property (nonatomic, copy) void (^doneButtonClickBlockWithPreviewType)(NSArray *photos,NSArray *assets,BOOL isSelectOriginalPhoto); 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZProgressView.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZProgressView.h 3 | // TZImagePickerController 4 | // 5 | // Created by ttouch on 2016/12/6. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TZProgressView : UIView 12 | 13 | @property (nonatomic, assign) double progress; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZProgressView.m: -------------------------------------------------------------------------------- 1 | // 2 | // TZProgressView.m 3 | // TZImagePickerController 4 | // 5 | // Created by ttouch on 2016/12/6. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import "TZProgressView.h" 10 | 11 | @interface TZProgressView () 12 | @property (nonatomic, strong) CAShapeLayer *progressLayer; 13 | @end 14 | 15 | @implementation TZProgressView 16 | 17 | - (instancetype)init { 18 | self = [super init]; 19 | if (self) { 20 | self.backgroundColor = [UIColor clearColor]; 21 | 22 | _progressLayer = [CAShapeLayer layer]; 23 | _progressLayer.fillColor = [[UIColor clearColor] CGColor]; 24 | _progressLayer.strokeColor = [[UIColor whiteColor] CGColor]; 25 | _progressLayer.opacity = 1; 26 | _progressLayer.lineCap = kCALineCapRound; 27 | _progressLayer.lineWidth = 5; 28 | 29 | [_progressLayer setShadowColor:[UIColor blackColor].CGColor]; 30 | [_progressLayer setShadowOffset:CGSizeMake(1, 1)]; 31 | [_progressLayer setShadowOpacity:0.5]; 32 | [_progressLayer setShadowRadius:2]; 33 | } 34 | return self; 35 | } 36 | 37 | - (void)drawRect:(CGRect)rect { 38 | CGPoint center = CGPointMake(rect.size.width / 2, rect.size.height / 2); 39 | CGFloat radius = rect.size.width / 2; 40 | CGFloat startA = - M_PI_2; 41 | CGFloat endA = - M_PI_2 + M_PI * 2 * _progress; 42 | _progressLayer.frame = self.bounds; 43 | UIBezierPath *path = [UIBezierPath bezierPathWithArcCenter:center radius:radius startAngle:startA endAngle:endA clockwise:YES]; 44 | _progressLayer.path =[path CGPath]; 45 | 46 | [_progressLayer removeFromSuperlayer]; 47 | [self.layer addSublayer:_progressLayer]; 48 | } 49 | 50 | - (void)setProgress:(double)progress { 51 | _progress = progress; 52 | [self setNeedsDisplay]; 53 | } 54 | 55 | @end 56 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoCropController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZVideoCropController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 肖兰月 on 2021/5/27. 6 | // Copyright © 2021 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @class TZAssetModel,TZImagePickerController; 14 | 15 | @interface TZVideoCropController : UIViewController 16 | @property (nonatomic, strong) TZAssetModel *model; 17 | @property (nonatomic, weak) TZImagePickerController *imagePickerVc; 18 | @end 19 | 20 | @protocol TZVideoEditViewDelegate 21 | - (void)editViewCropRectBeginChange; 22 | - (void)editViewCropRectEndChange; 23 | @end 24 | 25 | @interface TZVideoEditView : UIView 26 | @property (strong, nonatomic) UIImageView *beginImgView; 27 | @property (strong, nonatomic) UIImageView *endImgView; 28 | @property (strong, nonatomic) UIView *indicatorLine; 29 | @property (assign, nonatomic) CGFloat videoDuration; 30 | @property (assign, nonatomic) NSInteger maxCropVideoDuration; 31 | @property (assign, nonatomic) CGRect cropRect; 32 | @property (assign, nonatomic) CGFloat allImgWidth; 33 | @property (assign, nonatomic) CGFloat minCropRectWidth; 34 | 35 | @property (nonatomic, weak) id delegate; 36 | 37 | - (void)resetIndicatorLine; 38 | - (void)indicatorLineAnimateWithDuration:(NSTimeInterval)duration cropRect:(CGRect)cropRect; 39 | @end 40 | 41 | 42 | 43 | @interface TZVideoPictureCell : UICollectionViewCell 44 | @property (strong, nonatomic) UIImageView *imgView; 45 | @end 46 | 47 | NS_ASSUME_NONNULL_END 48 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoEditedPreviewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZVideoEditedPreviewController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 肖兰月 on 2021/5/29. 6 | // Copyright © 2021 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface TZVideoEditedPreviewController : UIViewController 14 | @property (nonatomic, copy) NSURL *videoURL; 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZVideoPlayerController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZVideoPlayerController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 16/1/5. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class TZAssetModel; 12 | @interface TZVideoPlayerController : UIViewController 13 | 14 | @property (nonatomic, strong) TZAssetModel *model; 15 | 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/UIView+TZLayout.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+TZLayout.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/2/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | typedef enum : NSUInteger { 12 | TZOscillatoryAnimationToBigger, 13 | TZOscillatoryAnimationToSmaller, 14 | } TZOscillatoryAnimationType; 15 | 16 | @interface UIView (TZLayout) 17 | 18 | @property (nonatomic) CGFloat tz_left; ///< Shortcut for frame.origin.x. 19 | @property (nonatomic) CGFloat tz_top; ///< Shortcut for frame.origin.y 20 | @property (nonatomic) CGFloat tz_right; ///< Shortcut for frame.origin.x + frame.size.width 21 | @property (nonatomic) CGFloat tz_bottom; ///< Shortcut for frame.origin.y + frame.size.height 22 | @property (nonatomic) CGFloat tz_width; ///< Shortcut for frame.size.width. 23 | @property (nonatomic) CGFloat tz_height; ///< Shortcut for frame.size.height. 24 | @property (nonatomic) CGFloat tz_centerX; ///< Shortcut for center.x 25 | @property (nonatomic) CGFloat tz_centerY; ///< Shortcut for center.y 26 | @property (nonatomic) CGPoint tz_origin; ///< Shortcut for frame.origin. 27 | @property (nonatomic) CGSize tz_size; ///< Shortcut for frame.size. 28 | 29 | + (void)showOscillatoryAnimationWithLayer:(CALayer *)layer type:(TZOscillatoryAnimationType)type; 30 | 31 | @end 32 | -------------------------------------------------------------------------------- /Pods/TZImagePickerController/TZImagePickerController/TZImagePickerController/UIView+TZLayout.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+TZLayout.m 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/2/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import "UIView+TZLayout.h" 10 | 11 | @implementation UIView (TZLayout) 12 | 13 | - (CGFloat)tz_left { 14 | return self.frame.origin.x; 15 | } 16 | 17 | - (void)setTz_left:(CGFloat)x { 18 | CGRect frame = self.frame; 19 | frame.origin.x = x; 20 | self.frame = frame; 21 | } 22 | 23 | - (CGFloat)tz_top { 24 | return self.frame.origin.y; 25 | } 26 | 27 | - (void)setTz_top:(CGFloat)y { 28 | CGRect frame = self.frame; 29 | frame.origin.y = y; 30 | self.frame = frame; 31 | } 32 | 33 | - (CGFloat)tz_right { 34 | return self.frame.origin.x + self.frame.size.width; 35 | } 36 | 37 | - (void)setTz_right:(CGFloat)right { 38 | CGRect frame = self.frame; 39 | frame.origin.x = right - frame.size.width; 40 | self.frame = frame; 41 | } 42 | 43 | - (CGFloat)tz_bottom { 44 | return self.frame.origin.y + self.frame.size.height; 45 | } 46 | 47 | - (void)setTz_bottom:(CGFloat)bottom { 48 | CGRect frame = self.frame; 49 | frame.origin.y = bottom - frame.size.height; 50 | self.frame = frame; 51 | } 52 | 53 | - (CGFloat)tz_width { 54 | return self.frame.size.width; 55 | } 56 | 57 | - (void)setTz_width:(CGFloat)width { 58 | CGRect frame = self.frame; 59 | frame.size.width = width; 60 | self.frame = frame; 61 | } 62 | 63 | - (CGFloat)tz_height { 64 | return self.frame.size.height; 65 | } 66 | 67 | - (void)setTz_height:(CGFloat)height { 68 | CGRect frame = self.frame; 69 | frame.size.height = height; 70 | self.frame = frame; 71 | } 72 | 73 | - (CGFloat)tz_centerX { 74 | return self.center.x; 75 | } 76 | 77 | - (void)setTz_centerX:(CGFloat)centerX { 78 | self.center = CGPointMake(centerX, self.center.y); 79 | } 80 | 81 | - (CGFloat)tz_centerY { 82 | return self.center.y; 83 | } 84 | 85 | - (void)setTz_centerY:(CGFloat)centerY { 86 | self.center = CGPointMake(self.center.x, centerY); 87 | } 88 | 89 | - (CGPoint)tz_origin { 90 | return self.frame.origin; 91 | } 92 | 93 | - (void)setTz_origin:(CGPoint)origin { 94 | CGRect frame = self.frame; 95 | frame.origin = origin; 96 | self.frame = frame; 97 | } 98 | 99 | - (CGSize)tz_size { 100 | return self.frame.size; 101 | } 102 | 103 | - (void)setTz_size:(CGSize)size { 104 | CGRect frame = self.frame; 105 | frame.size = size; 106 | self.frame = frame; 107 | } 108 | 109 | + (void)showOscillatoryAnimationWithLayer:(CALayer *)layer type:(TZOscillatoryAnimationType)type{ 110 | NSNumber *animationScale1 = type == TZOscillatoryAnimationToBigger ? @(1.15) : @(0.5); 111 | NSNumber *animationScale2 = type == TZOscillatoryAnimationToBigger ? @(0.92) : @(1.15); 112 | 113 | [UIView animateWithDuration:0.15 delay:0 options:UIViewAnimationOptionBeginFromCurrentState | UIViewAnimationOptionCurveEaseInOut animations:^{ 114 | [layer setValue:animationScale1 forKeyPath:@"transform.scale"]; 115 | } completion:^(BOOL finished) { 116 | [UIView animateWithDuration:0.15 delay:0 options:UIViewAnimationOptionBeginFromCurrentState | UIViewAnimationOptionCurveEaseInOut animations:^{ 117 | [layer setValue:animationScale2 forKeyPath:@"transform.scale"]; 118 | } completion:^(BOOL finished) { 119 | [UIView animateWithDuration:0.1 delay:0 options:UIViewAnimationOptionBeginFromCurrentState | UIViewAnimationOptionCurveEaseInOut animations:^{ 120 | [layer setValue:@(1.0) forKeyPath:@"transform.scale"]; 121 | } completion:nil]; 122 | }]; 123 | }]; 124 | } 125 | 126 | @end 127 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## SDWebImage 5 | 6 | Copyright (c) 2009-2017 Olivier Poitrey rs@dailymotion.com 7 | 8 | Permission is hereby granted, free of charge, to any person obtaining a copy 9 | of this software and associated documentation files (the "Software"), to deal 10 | in the Software without restriction, including without limitation the rights 11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 12 | copies of the Software, and to permit persons to whom the Software is furnished 13 | to do so, subject to the following conditions: 14 | 15 | The above copyright notice and this permission notice shall be included in all 16 | copies or substantial portions of the Software. 17 | 18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 21 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 23 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 24 | THE SOFTWARE. 25 | 26 | 27 | 28 | ## TZImagePickerController 29 | 30 | The MIT License (MIT) 31 | 32 | Copyright (c) 2016 Zhen Tan 33 | 34 | Permission is hereby granted, free of charge, to any person obtaining a copy 35 | of this software and associated documentation files (the "Software"), to deal 36 | in the Software without restriction, including without limitation the rights 37 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 38 | copies of the Software, and to permit persons to whom the Software is 39 | furnished to do so, subject to the following conditions: 40 | 41 | The above copyright notice and this permission notice shall be included in all 42 | copies or substantial portions of the Software. 43 | 44 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 45 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 46 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 47 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 48 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 49 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 50 | SOFTWARE. 51 | 52 | 53 | Generated by CocoaPods - https://cocoapods.org 54 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright (c) 2009-2017 Olivier Poitrey rs@dailymotion.com 18 | 19 | Permission is hereby granted, free of charge, to any person obtaining a copy 20 | of this software and associated documentation files (the "Software"), to deal 21 | in the Software without restriction, including without limitation the rights 22 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 23 | copies of the Software, and to permit persons to whom the Software is furnished 24 | to do so, subject to the following conditions: 25 | 26 | The above copyright notice and this permission notice shall be included in all 27 | copies or substantial portions of the Software. 28 | 29 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 30 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 31 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 32 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 33 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 34 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 35 | THE SOFTWARE. 36 | 37 | 38 | License 39 | MIT 40 | Title 41 | SDWebImage 42 | Type 43 | PSGroupSpecifier 44 | 45 | 46 | FooterText 47 | The MIT License (MIT) 48 | 49 | Copyright (c) 2016 Zhen Tan 50 | 51 | Permission is hereby granted, free of charge, to any person obtaining a copy 52 | of this software and associated documentation files (the "Software"), to deal 53 | in the Software without restriction, including without limitation the rights 54 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 55 | copies of the Software, and to permit persons to whom the Software is 56 | furnished to do so, subject to the following conditions: 57 | 58 | The above copyright notice and this permission notice shall be included in all 59 | copies or substantial portions of the Software. 60 | 61 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 62 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 63 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 64 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 65 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 66 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 67 | SOFTWARE. 68 | 69 | 70 | License 71 | MIT 72 | Title 73 | TZImagePickerController 74 | Type 75 | PSGroupSpecifier 76 | 77 | 78 | FooterText 79 | Generated by CocoaPods - https://cocoapods.org 80 | Title 81 | 82 | Type 83 | PSGroupSpecifier 84 | 85 | 86 | StringsTable 87 | Acknowledgements 88 | Title 89 | Acknowledgements 90 | 91 | 92 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_TZImagePreviewController : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_TZImagePreviewController 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-frameworks.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | 4 | echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 5 | mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 6 | 7 | SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" 8 | 9 | # This protects against multiple targets copying the same framework dependency at the same time. The solution 10 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html 11 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????") 12 | 13 | install_framework() 14 | { 15 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then 16 | local source="${BUILT_PRODUCTS_DIR}/$1" 17 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then 18 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" 19 | elif [ -r "$1" ]; then 20 | local source="$1" 21 | fi 22 | 23 | local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 24 | 25 | if [ -L "${source}" ]; then 26 | echo "Symlinked..." 27 | source="$(readlink "${source}")" 28 | fi 29 | 30 | # Use filter instead of exclude so missing patterns don't throw errors. 31 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" 32 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" 33 | 34 | local basename 35 | basename="$(basename -s .framework "$1")" 36 | binary="${destination}/${basename}.framework/${basename}" 37 | if ! [ -r "$binary" ]; then 38 | binary="${destination}/${basename}" 39 | fi 40 | 41 | # Strip invalid architectures so "fat" simulator / device frameworks work on device 42 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then 43 | strip_invalid_archs "$binary" 44 | fi 45 | 46 | # Resign the code if required by the build settings to avoid unstable apps 47 | code_sign_if_enabled "${destination}/$(basename "$1")" 48 | 49 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. 50 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then 51 | local swift_runtime_libs 52 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) 53 | for lib in $swift_runtime_libs; do 54 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" 55 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" 56 | code_sign_if_enabled "${destination}/${lib}" 57 | done 58 | fi 59 | } 60 | 61 | # Copies the dSYM of a vendored framework 62 | install_dsym() { 63 | local source="$1" 64 | if [ -r "$source" ]; then 65 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${DWARF_DSYM_FOLDER_PATH}\"" 66 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${DWARF_DSYM_FOLDER_PATH}" 67 | fi 68 | } 69 | 70 | # Signs a framework with the provided identity 71 | code_sign_if_enabled() { 72 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then 73 | # Use the current code_sign_identitiy 74 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" 75 | local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements '$1'" 76 | 77 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 78 | code_sign_cmd="$code_sign_cmd &" 79 | fi 80 | echo "$code_sign_cmd" 81 | eval "$code_sign_cmd" 82 | fi 83 | } 84 | 85 | # Strip invalid architectures 86 | strip_invalid_archs() { 87 | binary="$1" 88 | # Get architectures for current file 89 | archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" 90 | stripped="" 91 | for arch in $archs; do 92 | if ! [[ "${ARCHS}" == *"$arch"* ]]; then 93 | # Strip non-valid architectures in-place 94 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1 95 | stripped="$stripped $arch" 96 | fi 97 | done 98 | if [[ "$stripped" ]]; then 99 | echo "Stripped $binary of architectures:$stripped" 100 | fi 101 | } 102 | 103 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 104 | wait 105 | fi 106 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources-Debug-input-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${PODS_ROOT}/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources.sh 2 | ${PODS_ROOT}/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources-Debug-output-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/TZImagePickerController.bundle -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources-Release-input-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${PODS_ROOT}/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources.sh 2 | ${PODS_ROOT}/TZImagePickerController/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController-resources-Release-output-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/TZImagePickerController.bundle -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController.debug.xcconfig: -------------------------------------------------------------------------------- 1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/SDWebImage" "${PODS_ROOT}/Headers/Public/TZImagePickerController" 3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/SDWebImage" "${PODS_CONFIGURATION_BUILD_DIR}/TZImagePickerController" 4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/SDWebImage" -isystem "${PODS_ROOT}/Headers/Public/TZImagePickerController" 5 | OTHER_LDFLAGS = $(inherited) -ObjC -l"SDWebImage" -l"TZImagePickerController" -framework "ImageIO" -framework "Photos" 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 9 | PODS_ROOT = ${SRCROOT}/Pods 10 | -------------------------------------------------------------------------------- /Pods/Target Support Files/Pods-TZImagePreviewController/Pods-TZImagePreviewController.release.xcconfig: -------------------------------------------------------------------------------- 1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/SDWebImage" "${PODS_ROOT}/Headers/Public/TZImagePickerController" 3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/SDWebImage" "${PODS_CONFIGURATION_BUILD_DIR}/TZImagePickerController" 4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/SDWebImage" -isystem "${PODS_ROOT}/Headers/Public/TZImagePickerController" 5 | OTHER_LDFLAGS = $(inherited) -ObjC -l"SDWebImage" -l"TZImagePickerController" -framework "ImageIO" -framework "Photos" 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 9 | PODS_ROOT = ${SRCROOT}/Pods 10 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SDWebImage/SDWebImage-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_SDWebImage : NSObject 3 | @end 4 | @implementation PodsDummy_SDWebImage 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SDWebImage/SDWebImage-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/SDWebImage/SDWebImage.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/SDWebImage 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/SDWebImage" "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/SDWebImage" 4 | PODS_BUILD_DIR = ${BUILD_DIR} 5 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 6 | PODS_ROOT = ${SRCROOT} 7 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/SDWebImage 8 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 9 | SKIP_INSTALL = YES 10 | -------------------------------------------------------------------------------- /Pods/Target Support Files/TZImagePickerController/TZImagePickerController-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_TZImagePickerController : NSObject 3 | @end 4 | @implementation PodsDummy_TZImagePickerController 5 | @end 6 | -------------------------------------------------------------------------------- /Pods/Target Support Files/TZImagePickerController/TZImagePickerController-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /Pods/Target Support Files/TZImagePickerController/TZImagePickerController.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/TZImagePickerController 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/TZImagePickerController" "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/TZImagePickerController" 4 | PODS_BUILD_DIR = ${BUILD_DIR} 5 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 6 | PODS_ROOT = ${SRCROOT} 7 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/TZImagePickerController 8 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 9 | SKIP_INSTALL = YES 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # TZImagePreviewController 2 | [![CocoaPods](https://img.shields.io/cocoapods/v/TZImagePreviewController.svg?style=flat)](https://github.com/banchichen/TZImagePreviewController) 3 | 4 | Enhance the [TZImagePickerController](https://github.com/banchichen/TZImagePickerController) library, supports to preview photo by UIImage or NSURL and preview video by NSURL. 5 | 对[TZImagePickerController](https://github.com/banchichen/TZImagePickerController)库的增强,支持用UIImage、NSURL预览照片和用NSURL预览视频。 6 | 7 | ## 一. Installation 安装 8 | 9 | #### CocoaPods 10 | > pod 'TZImagePreviewController' 11 | 12 | #### 手动安装 13 | > 将TZImagePickerController文件夹拽入项目中,导入头文件:#import "TZImagePreviewController.h" 14 | 15 | ## 二. Example 例子 16 | 17 | ```objectivec 18 | TZImagePreviewController *previewVc = [[TZImagePreviewController alloc] initWithPhotos:self.selectedPhotos currentIndex:indexPath.row tzImagePickerVc:[self createTZImagePickerController]]; 19 | [previewVc setBackButtonClickBlock:^(BOOL isSelectOriginalPhoto) { 20 | NSLog(@"back isSelectOriginalPhoto:%d", isSelectOriginalPhoto); 21 | }]; 22 | [previewVc setSetImageWithURLBlock:^(NSURL *URL, UIImageView *imageView) { 23 | [imageView sd_setImageWithURL:URL]; 24 | }]; 25 | [previewVc setDoneButtonClickBlock:^(NSArray *photos, BOOL isSelectOriginalPhoto) { 26 | self.selectedPhotos = [NSMutableArray arrayWithArray:photos]; 27 | NSLog(@"done isSelectOriginalPhoto:%d photos.count:%zd", isSelectOriginalPhoto, photos.count); 28 | [self.collectionView reloadData]; 29 | }]; 30 | [self presentViewController:previewVc animated:YES completion:nil]; 31 | ``` 32 | 33 | ## 三. Requirements 要求 34 | iOS 8 or later. Requires ARC 35 | iOS8及以上系统可使用. ARC环境. 36 | 37 | ## 四. More 更多 38 | There is Demo inside, Please refer to Demo for usage. 39 | 内有Demo,请参考Demo进行使用。 40 | -------------------------------------------------------------------------------- /TZImagePreviewController.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = "TZImagePreviewController" 3 | s.version = "0.5.2" 4 | s.summary = "Enhance the TZImagePickerController library, supports to preview photo by UIImage or NSURL and preview video by NSURL." 5 | s.homepage = "https://github.com/banchichen/TZImagePreviewController" 6 | s.license = "MIT" 7 | s.author = { "banchichen" => "tanzhenios@foxmail.com" } 8 | s.platform = :ios 9 | s.ios.deployment_target = "8.0" 10 | s.source = { :git => "https://github.com/banchichen/TZImagePreviewController.git", :tag => "0.5.2" } 11 | s.requires_arc = true 12 | s.source_files = "TZImagePreviewController/TZImagePreviewController/*.{h,m}" 13 | s.frameworks = "Photos" 14 | s.dependency 'TZImagePickerController', '>=3.6.8' 15 | end 16 | -------------------------------------------------------------------------------- /TZImagePreviewController.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /TZImagePreviewController.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /TZImagePreviewController.xcodeproj/xcshareddata/xcschemes/TZImagePreviewController.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /TZImagePreviewController.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /TZImagePreviewController.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /TZImagePreviewController/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // TZImagePreviewController 4 | // 5 | // Created by 谭真 on 2018/8/23. 6 | // Copyright © 2018 Alibaba. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface AppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | 15 | 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /TZImagePreviewController/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // TZImagePreviewController 4 | // 5 | // Created by 谭真 on 2018/8/23. 6 | // Copyright © 2018 Alibaba. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | 11 | @interface AppDelegate () 12 | 13 | @end 14 | 15 | @implementation AppDelegate 16 | 17 | 18 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 19 | return YES; 20 | } 21 | 22 | 23 | - (void)applicationWillResignActive:(UIApplication *)application { 24 | 25 | } 26 | 27 | 28 | - (void)applicationDidEnterBackground:(UIApplication *)application { 29 | 30 | } 31 | 32 | 33 | - (void)applicationWillEnterForeground:(UIApplication *)application { 34 | 35 | } 36 | 37 | 38 | - (void)applicationDidBecomeActive:(UIApplication *)application { 39 | 40 | } 41 | 42 | 43 | - (void)applicationWillTerminate:(UIApplication *)application { 44 | 45 | } 46 | 47 | 48 | @end 49 | -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/AlbumAddBtn.imageset/AlbumAddBtn@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/TZImagePreviewController/Assets.xcassets/AlbumAddBtn.imageset/AlbumAddBtn@2x.png -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/AlbumAddBtn.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "scale" : "1x" 6 | }, 7 | { 8 | "idiom" : "universal", 9 | "filename" : "AlbumAddBtn@2x.png", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "20x20", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "20x20", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "29x29", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "29x29", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "40x40", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "40x40", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "size" : "60x60", 36 | "scale" : "2x" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "size" : "60x60", 41 | "scale" : "3x" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "size" : "20x20", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "size" : "20x20", 51 | "scale" : "2x" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "size" : "29x29", 56 | "scale" : "1x" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "size" : "29x29", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "size" : "40x40", 66 | "scale" : "1x" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "size" : "40x40", 71 | "scale" : "2x" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "size" : "76x76", 76 | "scale" : "1x" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "size" : "76x76", 81 | "scale" : "2x" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "size" : "83.5x83.5", 86 | "scale" : "2x" 87 | }, 88 | { 89 | "idiom" : "ios-marketing", 90 | "size" : "1024x1024", 91 | "scale" : "1x" 92 | } 93 | ], 94 | "info" : { 95 | "version" : 1, 96 | "author" : "xcode" 97 | } 98 | } -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/back.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "scale" : "1x" 6 | }, 7 | { 8 | "idiom" : "universal", 9 | "filename" : "back@2x.png", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/back.imageset/back@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/TZImagePreviewController/Assets.xcassets/back.imageset/back@2x.png -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/photo_delete.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "scale" : "1x" 6 | }, 7 | { 8 | "idiom" : "universal", 9 | "filename" : "photo_delete@2x.png", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /TZImagePreviewController/Assets.xcassets/photo_delete.imageset/photo_delete@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/TZImagePreviewController/Assets.xcassets/photo_delete.imageset/photo_delete@2x.png -------------------------------------------------------------------------------- /TZImagePreviewController/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /TZImagePreviewController/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 1、强依赖TZImagePickerController,无法单独使用。 31 | 2、目前仅支持UIImage、NSURL、PHAsset对象做预览。 32 | 3、Demo代码不多,请看懂再使用。 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /TZImagePreviewController/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(MARKETING_VERSION) 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | NSAppTransportSecurity 24 | 25 | NSAllowsArbitraryLoads 26 | 27 | 28 | NSCameraUsageDescription 29 | 访问相机以拍照 30 | NSLocationWhenInUseUsageDescription 31 | 允许定位以把位置保存到照片中 32 | NSMicrophoneUsageDescription 33 | 访问麦克风以录像 34 | NSPhotoLibraryUsageDescription 35 | 访问相册以选择照片 36 | UILaunchStoryboardName 37 | LaunchScreen 38 | UIMainStoryboardFile 39 | Main 40 | UIRequiredDeviceCapabilities 41 | 42 | armv7 43 | 44 | UISupportedInterfaceOrientations 45 | 46 | UIInterfaceOrientationPortrait 47 | UIInterfaceOrientationLandscapeLeft 48 | UIInterfaceOrientationLandscapeRight 49 | 50 | UISupportedInterfaceOrientations~ipad 51 | 52 | UIInterfaceOrientationPortrait 53 | UIInterfaceOrientationPortraitUpsideDown 54 | UIInterfaceOrientationLandscapeLeft 55 | UIInterfaceOrientationLandscapeRight 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /TZImagePreviewController/Sources/test_video.mov: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/banchichen/TZImagePreviewController/ae9cc8558dcf96561c2c4dae7286988175516201/TZImagePreviewController/Sources/test_video.mov -------------------------------------------------------------------------------- /TZImagePreviewController/TZImagePreviewController/TZImagePreviewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZImagePreviewController.h 3 | // TZImagePreviewController 4 | // 5 | // Created by 谭真 on 18/08/23. 6 | // Copyright © 2018年 谭真. All rights reserved. 7 | // version 0.5.2 - 2022.09.19 8 | // 更多信息,请前往项目的github地址:https://github.com/banchichen/TZImagePreviewController 9 | 10 | #import 11 | #import 12 | 13 | @interface TZImagePreviewController : UIViewController 14 | 15 | /** 16 | Use this init method / 用这个初始化方法 17 | 18 | @param photos 所有图片数组,支持PHAsset、UIImage、NSURL对象 19 | @param currentIndex 用户点击的图片的索引 20 | @param tzImagePickerVc 必传,主要是为了读取一些配置 21 | @return 一个TZImagePreviewController实例 22 | */ 23 | - (instancetype)initWithPhotos:(NSArray *)photos currentIndex:(NSInteger)currentIndex tzImagePickerVc:(TZImagePickerController *)tzImagePickerVc; 24 | 25 | /// 是否选择了原图 26 | @property (nonatomic, assign) BOOL isSelectOriginalPhoto; 27 | 28 | /// 是否需要显示底部的toolbar,默认YES 29 | @property (nonatomic, assign) BOOL isNeedShowToolbar; 30 | 31 | /// 传入的photos有NSURL对象时会触发,请使用你依赖的图片库给imageView设置图片 32 | @property (nonatomic, copy) void (^setImageWithURLBlock)(NSURL *URL, UIImageView *imageView, void (^completion)(void)); 33 | /// 用户点击了返回按钮 34 | @property (nonatomic, copy) void (^backButtonClickBlock)(BOOL isSelectOriginalPhoto); 35 | /// 用户点击了完成按钮 36 | @property (nonatomic, copy) void (^doneButtonClickBlock)(NSArray *photos,BOOL isSelectOriginalPhoto); 37 | 38 | - (void)doneButtonClick; 39 | @end 40 | -------------------------------------------------------------------------------- /TZImagePreviewController/TZTestCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // TZTestCell.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 16/1/3. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface TZTestCell : UICollectionViewCell 13 | 14 | @property (nonatomic, strong) UIImageView *imageView; 15 | @property (nonatomic, strong) UIImageView *videoImageView; 16 | @property (nonatomic, strong) UIButton *deleteBtn; 17 | @property (nonatomic, strong) UILabel *gifLable; 18 | @property (nonatomic, strong) id asset; 19 | 20 | @property (nonatomic, strong) NSURL *videoURL; 21 | @property (nonatomic, strong) AVPlayer *player; 22 | @property (nonatomic, strong) AVPlayerLayer *playerLayer; 23 | @end 24 | 25 | -------------------------------------------------------------------------------- /TZImagePreviewController/TZTestCell.m: -------------------------------------------------------------------------------- 1 | // 2 | // TZTestCell.m 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 16/1/3. 6 | // Copyright © 2016年 谭真. All rights reserved. 7 | // 8 | 9 | #import "TZTestCell.h" 10 | #import "UIView+TZLayout.h" 11 | #import 12 | #import "TZImagePickerController/TZImagePickerController.h" 13 | 14 | @implementation TZTestCell 15 | 16 | - (instancetype)initWithFrame:(CGRect)frame { 17 | self = [super initWithFrame:frame]; 18 | if (self) { 19 | self.backgroundColor = [UIColor whiteColor]; 20 | _imageView = [[UIImageView alloc] init]; 21 | _imageView.backgroundColor = [UIColor colorWithWhite:1.000 alpha:0.500]; 22 | _imageView.contentMode = UIViewContentModeScaleAspectFit; 23 | [self addSubview:_imageView]; 24 | self.clipsToBounds = YES; 25 | 26 | _videoImageView = [[UIImageView alloc] init]; 27 | _videoImageView.image = [UIImage tz_imageNamedFromMyBundle:@"MMVideoPreviewPlay"]; 28 | _videoImageView.contentMode = UIViewContentModeScaleAspectFill; 29 | _videoImageView.hidden = YES; 30 | [self addSubview:_videoImageView]; 31 | 32 | _deleteBtn = [UIButton buttonWithType:UIButtonTypeCustom]; 33 | [_deleteBtn setImage:[UIImage imageNamed:@"photo_delete"] forState:UIControlStateNormal]; 34 | _deleteBtn.imageEdgeInsets = UIEdgeInsetsMake(-10, 0, 0, -10); 35 | _deleteBtn.alpha = 0.6; 36 | [self addSubview:_deleteBtn]; 37 | 38 | _gifLable = [[UILabel alloc] init]; 39 | _gifLable.text = @"GIF"; 40 | _gifLable.textColor = [UIColor whiteColor]; 41 | _gifLable.backgroundColor = [UIColor colorWithRed:0 green:0 blue:0 alpha:0.8]; 42 | _gifLable.textAlignment = NSTextAlignmentCenter; 43 | _gifLable.font = [UIFont systemFontOfSize:10]; 44 | [self addSubview:_gifLable]; 45 | } 46 | return self; 47 | } 48 | 49 | - (void)layoutSubviews { 50 | [super layoutSubviews]; 51 | _imageView.frame = self.bounds; 52 | _gifLable.frame = CGRectMake(self.tz_width - 25, self.tz_height - 14, 25, 14); 53 | _deleteBtn.frame = CGRectMake(self.tz_width - 36, 0, 36, 36); 54 | CGFloat width = self.tz_width / 3.0; 55 | _videoImageView.frame = CGRectMake(width, width, width, width); 56 | [self bringSubviewToFront:_videoImageView]; 57 | _playerLayer.frame = self.bounds; 58 | } 59 | 60 | - (void)setAsset:(PHAsset *)asset { 61 | _asset = asset; 62 | if ([asset isKindOfClass:[PHAsset class]]) { 63 | _videoImageView.hidden = asset.mediaType != PHAssetMediaTypeVideo; 64 | _gifLable.hidden = ![[asset valueForKey:@"filename"] containsString:@"GIF"]; 65 | } else { 66 | if ([asset isKindOfClass:[NSURL class]]) { 67 | NSURL *URL = (NSURL *)asset; 68 | _gifLable.hidden = ![URL.absoluteString.lowercaseString hasSuffix:@"gif"]; 69 | } else { 70 | _gifLable.hidden = YES; 71 | } 72 | } 73 | [self configMoviePlayer]; 74 | } 75 | 76 | - (void)setVideoURL:(NSURL *)videoURL { 77 | _videoURL = videoURL; 78 | [self configMoviePlayer]; 79 | } 80 | 81 | - (void)configMoviePlayer { 82 | if (_player) { 83 | [_playerLayer removeFromSuperlayer]; 84 | _playerLayer = nil; 85 | [_player pause]; 86 | _player = nil; 87 | } 88 | 89 | self.videoImageView.hidden = !self.videoURL; 90 | if (self.videoURL) { 91 | // 这个处理比较耗内存,最好是只用UIImageView显示视频的封面(服务端返回),不创建AVPlayer 92 | AVPlayerItem *playerItem = [AVPlayerItem playerItemWithURL:self.videoURL]; 93 | self.player = [AVPlayer playerWithPlayerItem:playerItem]; 94 | self.playerLayer = [AVPlayerLayer playerLayerWithPlayer:self.player]; 95 | self.playerLayer.backgroundColor = [UIColor blackColor].CGColor; 96 | self.playerLayer.frame = self.bounds; 97 | [self.layer addSublayer:self.playerLayer]; 98 | // 如cell内也需要播放视频,打开下面的注释即可,需注意会导致内存升高。同时需监听播放结束、应用回到后台的通知,将播放重置到起点或暂停,参考TZVideoPreviewCell内的处理 99 | // [self.player play]; 100 | // self.videoImageView.hidden = YES; 101 | } 102 | } 103 | 104 | @end 105 | -------------------------------------------------------------------------------- /TZImagePreviewController/ViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.h 3 | // TZImagePickerController 4 | // 5 | // Created by 谭真 on 15/12/24. 6 | // Copyright © 2015年 谭真. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ViewController : UIViewController 12 | 13 | 14 | @end 15 | 16 | -------------------------------------------------------------------------------- /TZImagePreviewController/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // TZImagePreviewController 4 | // 5 | // Created by 谭真 on 2018/8/23. 6 | // Copyright © 2018 Alibaba. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "AppDelegate.h" 11 | 12 | int main(int argc, char * argv[]) { 13 | @autoreleasepool { 14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 15 | } 16 | } 17 | --------------------------------------------------------------------------------