Skip to content

Commit

Permalink
spec error fix
Browse files Browse the repository at this point in the history
  • Loading branch information
duzexu committed Nov 21, 2024
1 parent fe24c24 commit 0fbf584
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 8 deletions.
4 changes: 1 addition & 3 deletions ADPhotoKit.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,7 @@ Pod::Spec.new do |s|
end

s.subspec "VideoEdit" do |video|
video.dependency 'ADPhotoKit/Base'
video.dependency 'SnapKit'
video.dependency 'Kingfisher'
video.dependency 'ADPhotoKit/CoreUI'
video.source_files = ["ADPhotoKit/Classes/VideoEdit/**/*.swift","ADPhotoKit/Classes/EditCore/**/*.swift"]
video.pod_target_xcconfig = { 'SWIFT_ACTIVE_COMPILATION_CONDITIONS' => 'Module_VideoEdit'}
video.resource_bundles = {
Expand Down
12 changes: 10 additions & 2 deletions ADPhotoKit/Classes/CoreUI/ADPhotoKitUI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,12 @@ public struct ADConstraintParams {

extension ADSelectAssetModel {
func result(image: UIImage?) -> ADAssetResult? {
#if Module_ImageEdit || Module_VideoEdit
#if Module_ImageEdit && Module_VideoEdit
return ADAssetResult(image: image, asset: nil, imageEditInfo: imageEditInfo, videoEditInfo: videoEditInfo)
#elseif Module_ImageEdit
return ADAssetResult(image: image, asset: nil, imageEditInfo: imageEditInfo)
#elseif Module_VideoEdit
return ADAssetResult(image: image, asset: nil, videoEditInfo: videoEditInfo)
#else
if let img = image {
return ADAssetResult(image: img, asset: nil)
Expand All @@ -84,8 +88,12 @@ extension ADSelectAssetModel {
}

func result(asset: AVAsset?) -> ADAssetResult? {
#if Module_ImageEdit || Module_VideoEdit
#if Module_ImageEdit && Module_VideoEdit
return ADAssetResult(image: nil, asset: asset, imageEditInfo: imageEditInfo, videoEditInfo: videoEditInfo)
#elseif Module_ImageEdit
return ADAssetResult(image: nil, asset: asset, imageEditInfo: imageEditInfo)
#elseif Module_VideoEdit
return ADAssetResult(image: nil, asset: asset, videoEditInfo: videoEditInfo)
#else
if let asset = asset {
return ADAssetResult(image: nil, asset: asset)
Expand Down
5 changes: 2 additions & 3 deletions Example/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ PODS:
- ADPhotoKit/Base
- SnapKit
- ADPhotoKit/VideoEdit (1.5.0):
- ADPhotoKit/Base
- SnapKit
- ADPhotoKit/CoreUI
- Kingfisher (6.3.1)
- ProgressHUD (2.70)
- SnapKit (5.6.0)
Expand All @@ -38,7 +37,7 @@ EXTERNAL SOURCES:
:path: "../"

SPEC CHECKSUMS:
ADPhotoKit: 558f4567b49193f2952620e4c38dc1d1cc59376b
ADPhotoKit: 3f07236302c703e8b0f7161275f51c3e3dc09ead
Kingfisher: 016c8b653a35add51dd34a3aba36b580041acc74
ProgressHUD: e603e8b8622c47d8818b9fb38b3cfe9d3e7ca421
SnapKit: e01d52ebb8ddbc333eefe2132acf85c8227d9c25
Expand Down

0 comments on commit 0fbf584

Please sign in to comment.