From d7eec31a2acd27a26b207a5b090a9138528145d4 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Fri, 19 Jul 2019 15:44:41 +0800 Subject: [PATCH 01/10] build(git): update `.gitignore` --- .gitignore | 121 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 121 insertions(+) diff --git a/.gitignore b/.gitignore index 4de476ab4..8f698a0a2 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,124 @@ wfuikit/bin wfuikit/bin_tmp wfuikit/Frameworks wfuikit/WFChatUIKit.xcodeproj/xcuserdata + +# General +.DS_Store +.AppleDouble +.LSOverride + +# Icon must end with two \r +Icon + + +# Thumbnails +._* + +# Files that might appear in the root of a volume +.DocumentRevisions-V100 +.fseventsd +.Spotlight-V100 +.TemporaryItems +.Trashes +.VolumeIcon.icns +.com.apple.timemachine.donotpresent + +# Directories potentially created on remote AFP share +.AppleDB +.AppleDesktop +Network Trash Folder +Temporary Items +.apdisk + +# Xcode +# +# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore + +## Build generated +build/ +DerivedData/ +Index/ + +## Various settings +*.pbxuser +!default.pbxuser +*.mode1v3 +!default.mode1v3 +*.mode2v3 +!default.mode2v3 +*.perspectivev3 +!default.perspectivev3 +xcuserdata/ + +## Xcode Patch +*.xcodeproj/* +!*.xcodeproj/project.pbxproj +!*.xcodeproj/xcshareddata/ +!*.xcworkspace/contents.xcworkspacedata +/*.gcno + +## Other +*.moved-aside +*.xccheckout +*.xcscmblueprint +*.log +cert/ +export/ + +## Obj-C/Swift specific +*.hmap +*.ipa +*.dSYM.zip +*.dSYM + +## Playgrounds +timeline.xctimeline +playground.xcworkspace + +# Swift Package Manager +# +# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies. +# Packages/ +# Package.pins +# Package.resolved +.build/ + +# CocoaPods +# +# We recommend against adding the Pods directory to your .gitignore. However +# you should judge for yourself, the pros and cons are mentioned at: +# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control +Pods/ + +# Add this line if you want to avoid checking in source code from the Xcode workspace +# *.xcworkspace + +# Carthage +# +# Add this line if you want to avoid checking in source code from Carthage dependencies. +# Carthage/Checkouts +Carthage/Build + +# Accio dependency management +Dependencies/ +.accio/ + +# fastlane +# +# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the +# screenshots whenever they are needed. +# For more information about the recommended setup visit: +# https://docs.fastlane.tools/best-practices/source-control/#source-control +fastlane/report.xml +fastlane/Preview.html +fastlane/screenshots/**/*.png +fastlane/test_output + +# Code Injection +# +# After new code Injection tools there's a generated folder /iOSInjectionProject +# https://github.com/johnno1962/injectionforxcode +iOSInjectionProject/ + +# R.swift +*.generated.swift \ No newline at end of file From d79124d90d313010fed7540db400a08598828527 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Fri, 19 Jul 2019 20:37:04 +0800 Subject: [PATCH 02/10] build(pods): add `podspec` of WFChatClient and WFChatUIKit SDK, then use Cocoapods to install within workspace --- wfchat/Podfile | 12 ++ wfchat/Podfile.lock | 130 +++++++++++++++ wfchat/WildFireChat.xcodeproj/project.pbxproj | 134 +++++++++------- .../contents.xcworkspacedata | 10 ++ .../xcshareddata/IDEWorkspaceChecks.plist | 8 + wfclient/WFChatClient.podspec | 47 ++++++ wfuikit/WFChatUIKit.podspec | 151 ++++++++++++++++++ 7 files changed, 432 insertions(+), 60 deletions(-) create mode 100644 wfchat/Podfile create mode 100644 wfchat/Podfile.lock create mode 100644 wfchat/WildFireChat.xcworkspace/contents.xcworkspacedata create mode 100644 wfchat/WildFireChat.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist create mode 100644 wfclient/WFChatClient.podspec create mode 100644 wfuikit/WFChatUIKit.podspec diff --git a/wfchat/Podfile b/wfchat/Podfile new file mode 100644 index 000000000..d241056f0 --- /dev/null +++ b/wfchat/Podfile @@ -0,0 +1,12 @@ +source 'https://github.com/CocoaPods/Specs.git' + +platform :ios, '8.0' + +use_frameworks! + +target 'WildFireChat' do + + pod 'WFChatClient', :path => '../wfclient' + pod 'WFChatUIKit', :path => '../wfuikit' + +end diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock new file mode 100644 index 000000000..215e14077 --- /dev/null +++ b/wfchat/Podfile.lock @@ -0,0 +1,130 @@ +PODS: + - WFChatClient (1.0): + - WFChatClient/amr (= 1.0) + - WFChatClient/Client (= 1.0) + - WFChatClient/Messages (= 1.0) + - WFChatClient/Model (= 1.0) + - WFChatClient/Proto (= 1.0) + - WFChatClient/Utility (= 1.0) + - WFChatClient/amr (1.0) + - WFChatClient/Client (1.0) + - WFChatClient/Messages (1.0) + - WFChatClient/Model (1.0) + - WFChatClient/Proto (1.0) + - WFChatClient/Utility (1.0) + - WFChatUIKit (1.0): + - WFChatClient + - WFChatUIKit/AddFriend (= 1.0) + - WFChatUIKit/AVEngine (= 1.0) + - WFChatUIKit/Category (= 1.0) + - WFChatUIKit/Channel (= 1.0) + - WFChatUIKit/CommonVC (= 1.0) + - WFChatUIKit/Contacts (= 1.0) + - WFChatUIKit/ConversationList (= 1.0) + - WFChatUIKit/ConversationSetting (= 1.0) + - WFChatUIKit/CreateGroup (= 1.0) + - WFChatUIKit/ForwardMessage (= 1.0) + - WFChatUIKit/FriendRequest (= 1.0) + - WFChatUIKit/Group (= 1.0) + - WFChatUIKit/Me (= 1.0) + - WFChatUIKit/MessageList (= 1.0) + - WFChatUIKit/SelectMentionVC (= 1.0) + - WFChatUIKit/Utilities (= 1.0) + - WFChatUIKit/Vendor (= 1.0) + - WFChatUIKit/Voip (= 1.0) + - WFChatUIKit/AddFriend (1.0): + - WFChatClient + - WFChatUIKit/AVEngine (1.0): + - WFChatClient + - WFChatUIKit/Category (1.0): + - WFChatClient + - WFChatUIKit/Channel (1.0): + - WFChatClient + - WFChatUIKit/CommonVC (1.0): + - WFChatClient + - WFChatUIKit/Contacts (1.0): + - WFChatClient + - WFChatUIKit/ConversationList (1.0): + - WFChatClient + - WFChatUIKit/ConversationSetting (1.0): + - WFChatClient + - WFChatUIKit/CreateGroup (1.0): + - WFChatClient + - WFChatUIKit/ForwardMessage (1.0): + - WFChatClient + - WFChatUIKit/FriendRequest (1.0): + - WFChatClient + - WFChatUIKit/Group (1.0): + - WFChatClient + - WFChatUIKit/Me (1.0): + - WFChatClient + - WFChatUIKit/MessageList (1.0): + - WFChatClient + - WFChatUIKit/SelectMentionVC (1.0): + - WFChatClient + - WFChatUIKit/Utilities (1.0): + - WFChatClient + - WFChatUIKit/Vendor (1.0): + - WFChatClient + - WFChatUIKit/Vendor/AFNetworking (= 1.0) + - WFChatUIKit/Vendor/CCHMapClusterController (= 1.0) + - WFChatUIKit/Vendor/ChatInputBar (= 1.0) + - WFChatUIKit/Vendor/KxMenu (= 1.0) + - WFChatUIKit/Vendor/KZSmallVideoRecorder (= 1.0) + - WFChatUIKit/Vendor/MBProgressHUD (= 1.0) + - WFChatUIKit/Vendor/Pinyin (= 1.0) + - WFChatUIKit/Vendor/SDPhotoBrowser (= 1.0) + - WFChatUIKit/Vendor/SDRefeshView (= 1.0) + - WFChatUIKit/Vendor/SDWebImage (= 1.0) + - WFChatUIKit/Vendor/TYAlertController (= 1.0) + - WFChatUIKit/Vendor/UITextViewPlaceholder (= 1.0) + - WFChatUIKit/Vendor/VideoPlayerKit (= 1.0) + - WFChatUIKit/Vendor/YLGIFImage (= 1.0) + - WFChatUIKit/Vendor/AFNetworking (1.0): + - WFChatClient + - WFChatUIKit/Vendor/CCHMapClusterController (1.0): + - WFChatClient + - WFChatUIKit/Vendor/ChatInputBar (1.0): + - WFChatClient + - WFChatUIKit/Vendor/KxMenu (1.0): + - WFChatClient + - WFChatUIKit/Vendor/KZSmallVideoRecorder (1.0): + - WFChatClient + - WFChatUIKit/Vendor/MBProgressHUD (1.0): + - WFChatClient + - WFChatUIKit/Vendor/Pinyin (1.0): + - WFChatClient + - WFChatUIKit/Vendor/SDPhotoBrowser (1.0): + - WFChatClient + - WFChatUIKit/Vendor/SDRefeshView (1.0): + - WFChatClient + - WFChatUIKit/Vendor/SDWebImage (1.0): + - WFChatClient + - WFChatUIKit/Vendor/TYAlertController (1.0): + - WFChatClient + - WFChatUIKit/Vendor/UITextViewPlaceholder (1.0): + - WFChatClient + - WFChatUIKit/Vendor/VideoPlayerKit (1.0): + - WFChatClient + - WFChatUIKit/Vendor/YLGIFImage (1.0): + - WFChatClient + - WFChatUIKit/Voip (1.0): + - WFChatClient + +DEPENDENCIES: + - WFChatClient (from `../wfclient`) + - WFChatUIKit (from `../wfuikit`) + +EXTERNAL SOURCES: + WFChatClient: + :path: "../wfclient" + WFChatUIKit: + :path: "../wfuikit" + +SPEC CHECKSUMS: + WFChatClient: 8195d6eb2afc32b8d37f15980d8e176ecf0814cb + WFChatUIKit: 995a75f36d80f0c6f0d8a3c5b99304d3c3bad3fb + +PODFILE CHECKSUM: b3a937c88865791df4f5e2f0cef525a0429d5067 + +COCOAPODS: 1.7.4 diff --git a/wfchat/WildFireChat.xcodeproj/project.pbxproj b/wfchat/WildFireChat.xcodeproj/project.pbxproj index 760cf3164..ed7558590 100644 --- a/wfchat/WildFireChat.xcodeproj/project.pbxproj +++ b/wfchat/WildFireChat.xcodeproj/project.pbxproj @@ -15,12 +15,9 @@ 2E1D20B01FAF125D00F4405D /* WFCBaseTabBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20AF1FAF125D00F4405D /* WFCBaseTabBarController.m */; }; 2E1D20D41FAF127100F4405D /* WFCConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20B11FAF127100F4405D /* WFCConfig.m */; }; 2E1D20D91FAF127100F4405D /* DiscoverViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20BE1FAF127100F4405D /* DiscoverViewController.m */; }; - 2E56F6CA20AAEBA00063B4D6 /* WFAVEngineKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2E56F6C820AAEB9F0063B4D6 /* WFAVEngineKit.framework */; }; - 2E56F6CB20AAEBA00063B4D6 /* WFChatClient.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2E56F6C920AAEB9F0063B4D6 /* WFChatClient.framework */; }; 2F143A70217F7DA900B3E38A /* Emoj.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A6D217F7DA900B3E38A /* Emoj.plist */; }; 2F143A72217F7DA900B3E38A /* Stickers.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A6F217F7DA900B3E38A /* Stickers.bundle */; }; 2F143A81217F86BA00B3E38A /* WFChatUIKit.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A80217F86B900B3E38A /* WFChatUIKit.xcassets */; }; - 2F143A84217F876C00B3E38A /* WFChatUIKit.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 2F550E28217F58AE00F56C26 /* WFChatUIKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 2F1B0DCF21E19AF400139CB1 /* UserNotificationsUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCC21E19AF400139CB1 /* UserNotificationsUI.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; 2F1B0DD021E19AF400139CB1 /* NotificationCenter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCD21E19AF400139CB1 /* NotificationCenter.framework */; }; 2F1B0DD121E19AF400139CB1 /* UserNotifications.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCE21E19AF400139CB1 /* UserNotifications.framework */; }; @@ -28,7 +25,6 @@ 2F1B0DD521E1E29400139CB1 /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DD421E1E29400139CB1 /* AudioToolbox.framework */; }; 2F1B0DEE21E2161E00139CB1 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DED21E2161E00139CB1 /* CoreTelephony.framework */; }; 2F25F747219ECFD100FFABF9 /* WFCUShareMessageView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */; }; - 2F550E29217F58AE00F56C26 /* WFChatUIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F550E28217F58AE00F56C26 /* WFChatUIKit.framework */; }; 2F623A5022DCBD3E00CB3C65 /* Album.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2F623A4F22DCBD3E00CB3C65 /* Album.xcassets */; }; 2F7268F921F7136600E05F9C /* WFCPrivacyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2F7268F821F7136600E05F9C /* WFCPrivacyViewController.m */; }; 2F7268FD21F714C900E05F9C /* UILabel+YBAttributeTextTapAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 2F7268FB21F714C900E05F9C /* UILabel+YBAttributeTextTapAction.m */; }; @@ -57,11 +53,6 @@ 2FF07F5D21F82E7200A78A62 /* WFCMeTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2FF07F5121F82E7200A78A62 /* WFCMeTableViewCell.m */; }; 2FF07F5E21F82E7200A78A62 /* WFCMeTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2FF07F5421F82E7200A78A62 /* WFCMeTableViewController.m */; }; 2FF07F5F21F82E7200A78A62 /* WFCSecurityTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2FF07F5521F82E7200A78A62 /* WFCSecurityTableViewController.m */; }; - 6E616DA020AB3435002CB8BE /* LICENSE.md in Resources */ = {isa = PBXBuildFile; fileRef = 6E616D9B20AB3435002CB8BE /* LICENSE.md */; }; - 6E616DA220AB3435002CB8BE /* WebRTC.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6E616D9F20AB3435002CB8BE /* WebRTC.framework */; }; - 6E616DB520AB3540002CB8BE /* WebRTC.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 6E616D9F20AB3435002CB8BE /* WebRTC.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; - 6E616DB720AB3540002CB8BE /* WFAVEngineKit.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 2E56F6C820AAEB9F0063B4D6 /* WFAVEngineKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; - 6E616DB920AB3540002CB8BE /* WFChatClient.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 2E56F6C920AAEB9F0063B4D6 /* WFChatClient.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 9051774C2243CD830020A2AC /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774B2243CD830020A2AC /* SystemConfiguration.framework */; }; 9051774E2243CD8D0020A2AC /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774D2243CD8D0020A2AC /* Security.framework */; }; 905177502243CD9A0020A2AC /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774F2243CD9A0020A2AC /* libz.tbd */; }; @@ -78,6 +69,7 @@ 90C1D912208C12A900E923F4 /* ring.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 90C1D910208C12A900E923F4 /* ring.mp3 */; }; 90E927F222DFF45F00F168BC /* WFCPrivacyTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 90E927F122DFF45F00F168BC /* WFCPrivacyTableViewController.m */; }; 90FF267E222AB34B0001D8AF /* PCLoginConfirmViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 90FF267D222AB34B0001D8AF /* PCLoginConfirmViewController.m */; }; + D478DF6BE018DA990EA91F54 /* Pods_WildFireChat.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 20595D62708F726D5A46BAD2 /* Pods_WildFireChat.framework */; }; /* End PBXBuildFile section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -87,10 +79,6 @@ dstPath = ""; dstSubfolderSpec = 10; files = ( - 2F143A84217F876C00B3E38A /* WFChatUIKit.framework in Embed Frameworks */, - 6E616DB520AB3540002CB8BE /* WebRTC.framework in Embed Frameworks */, - 6E616DB920AB3540002CB8BE /* WFChatClient.framework in Embed Frameworks */, - 6E616DB720AB3540002CB8BE /* WFAVEngineKit.framework in Embed Frameworks */, ); name = "Embed Frameworks"; runOnlyForDeploymentPostprocessing = 0; @@ -98,6 +86,7 @@ /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ + 20595D62708F726D5A46BAD2 /* Pods_WildFireChat.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_WildFireChat.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 2E1D1FF71FAF0AE600F4405D /* WildFireChat.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = WildFireChat.app; sourceTree = BUILT_PRODUCTS_DIR; }; 2E1D1FFA1FAF0AE600F4405D /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 2E1D1FFB1FAF0AE600F4405D /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; @@ -112,8 +101,6 @@ 2E1D20BB1FAF127100F4405D /* WFCConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WFCConfig.h; sourceTree = ""; }; 2E1D20BD1FAF127100F4405D /* DiscoverViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DiscoverViewController.h; sourceTree = ""; }; 2E1D20BE1FAF127100F4405D /* DiscoverViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DiscoverViewController.m; sourceTree = ""; }; - 2E56F6C820AAEB9F0063B4D6 /* WFAVEngineKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WFAVEngineKit.framework; path = Frameworks/WFAVEngineKit.framework; sourceTree = SOURCE_ROOT; }; - 2E56F6C920AAEB9F0063B4D6 /* WFChatClient.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WFChatClient.framework; path = Frameworks/WFChatClient.framework; sourceTree = SOURCE_ROOT; }; 2EF30A58201995630060992B /* WildFireChat.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = WildFireChat.entitlements; sourceTree = ""; }; 2F143A02217F5F3700B3E38A /* NSImage+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSImage+WebCache.h"; sourceTree = ""; }; 2F143A03217F5F3700B3E38A /* UIImageView+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+WebCache.h"; sourceTree = ""; }; @@ -157,7 +144,6 @@ 2F1B0DD421E1E29400139CB1 /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; }; 2F1B0DED21E2161E00139CB1 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; }; 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; name = WFCUShareMessageView.xib; path = Frameworks/WFCUShareMessageView.xib; sourceTree = SOURCE_ROOT; }; - 2F550E28217F58AE00F56C26 /* WFChatUIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WFChatUIKit.framework; path = Frameworks/WFChatUIKit.framework; sourceTree = SOURCE_ROOT; }; 2F623A4F22DCBD3E00CB3C65 /* Album.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Album.xcassets; sourceTree = ""; }; 2F7268F721F7136600E05F9C /* WFCPrivacyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WFCPrivacyViewController.h; sourceTree = ""; }; 2F7268F821F7136600E05F9C /* WFCPrivacyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCPrivacyViewController.m; sourceTree = ""; }; @@ -212,8 +198,6 @@ 2FF07F5321F82E7200A78A62 /* WFCAboutViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WFCAboutViewController.h; sourceTree = ""; }; 2FF07F5421F82E7200A78A62 /* WFCMeTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCMeTableViewController.m; sourceTree = ""; }; 2FF07F5521F82E7200A78A62 /* WFCSecurityTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCSecurityTableViewController.m; sourceTree = ""; }; - 6E616D9B20AB3435002CB8BE /* LICENSE.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; name = LICENSE.md; path = Frameworks/GoogleWebRTC/LICENSE.md; sourceTree = SOURCE_ROOT; }; - 6E616D9F20AB3435002CB8BE /* WebRTC.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebRTC.framework; path = Frameworks/GoogleWebRTC/Frameworks/frameworks/WebRTC.framework; sourceTree = SOURCE_ROOT; }; 9051774B2243CD830020A2AC /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; 9051774D2243CD8D0020A2AC /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; 9051774F2243CD9A0020A2AC /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; @@ -239,6 +223,8 @@ 90E927F122DFF45F00F168BC /* WFCPrivacyTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCPrivacyTableViewController.m; sourceTree = ""; }; 90FF267C222AB34B0001D8AF /* PCLoginConfirmViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PCLoginConfirmViewController.h; sourceTree = ""; }; 90FF267D222AB34B0001D8AF /* PCLoginConfirmViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PCLoginConfirmViewController.m; sourceTree = ""; }; + BD75A85E3A5B064156463D7B /* Pods-WildFireChat.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-WildFireChat.debug.xcconfig"; path = "Target Support Files/Pods-WildFireChat/Pods-WildFireChat.debug.xcconfig"; sourceTree = ""; }; + F7251BFDCF08A4943E07D265 /* Pods-WildFireChat.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-WildFireChat.release.xcconfig"; path = "Target Support Files/Pods-WildFireChat/Pods-WildFireChat.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -256,10 +242,7 @@ 2F1B0DCF21E19AF400139CB1 /* UserNotificationsUI.framework in Frameworks */, 2F1B0DD021E19AF400139CB1 /* NotificationCenter.framework in Frameworks */, 2F1B0DD121E19AF400139CB1 /* UserNotifications.framework in Frameworks */, - 2F550E29217F58AE00F56C26 /* WFChatUIKit.framework in Frameworks */, - 2E56F6CB20AAEBA00063B4D6 /* WFChatClient.framework in Frameworks */, - 2E56F6CA20AAEBA00063B4D6 /* WFAVEngineKit.framework in Frameworks */, - 6E616DA220AB3435002CB8BE /* WebRTC.framework in Frameworks */, + D478DF6BE018DA990EA91F54 /* Pods_WildFireChat.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -272,6 +255,7 @@ 2E1D1FF91FAF0AE600F4405D /* WildFireChat */, 2EAC88E61FB0A0D6004B34D1 /* Frameworks */, 2E1D1FF81FAF0AE600F4405D /* Products */, + 3123ECBB7BBF84AD128BA41C /* Pods */, ); sourceTree = ""; }; @@ -337,10 +321,7 @@ 2F143A6D217F7DA900B3E38A /* Emoj.plist */, 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */, 2F143A6F217F7DA900B3E38A /* Stickers.bundle */, - 2F550E28217F58AE00F56C26 /* WFChatUIKit.framework */, - 6E616D9A20AB3435002CB8BE /* GoogleWebRTC */, - 2E56F6C820AAEB9F0063B4D6 /* WFAVEngineKit.framework */, - 2E56F6C920AAEB9F0063B4D6 /* WFChatClient.framework */, + 20595D62708F726D5A46BAD2 /* Pods_WildFireChat.framework */, ); path = Frameworks; sourceTree = ""; @@ -554,30 +535,13 @@ path = Me; sourceTree = ""; }; - 6E616D9A20AB3435002CB8BE /* GoogleWebRTC */ = { + 3123ECBB7BBF84AD128BA41C /* Pods */ = { isa = PBXGroup; children = ( - 6E616D9B20AB3435002CB8BE /* LICENSE.md */, - 6E616D9D20AB3435002CB8BE /* Frameworks */, + BD75A85E3A5B064156463D7B /* Pods-WildFireChat.debug.xcconfig */, + F7251BFDCF08A4943E07D265 /* Pods-WildFireChat.release.xcconfig */, ); - name = GoogleWebRTC; - path = Frameworks/GoogleWebRTC; - sourceTree = SOURCE_ROOT; - }; - 6E616D9D20AB3435002CB8BE /* Frameworks */ = { - isa = PBXGroup; - children = ( - 6E616D9E20AB3435002CB8BE /* frameworks */, - ); - path = Frameworks; - sourceTree = ""; - }; - 6E616D9E20AB3435002CB8BE /* frameworks */ = { - isa = PBXGroup; - children = ( - 6E616D9F20AB3435002CB8BE /* WebRTC.framework */, - ); - path = frameworks; + path = Pods; sourceTree = ""; }; 903EBC942136313B00312C16 /* SupportFiles */ = { @@ -624,10 +588,12 @@ isa = PBXNativeTarget; buildConfigurationList = 2E1D200D1FAF0AE600F4405D /* Build configuration list for PBXNativeTarget "WildFireChat" */; buildPhases = ( + A35FD823BEB204251F158C61 /* [CP] Check Pods Manifest.lock */, 2E1D1FF31FAF0AE600F4405D /* Sources */, 2E1D1FF41FAF0AE600F4405D /* Frameworks */, 2E1D1FF51FAF0AE600F4405D /* Resources */, 90C1D90A208C104400E923F4 /* Embed Frameworks */, + 125431A15AF9FAE394C0609A /* [CP] Embed Pods Frameworks */, ); buildRules = ( ); @@ -649,7 +615,7 @@ TargetAttributes = { 2E1D1FF61FAF0AE600F4405D = { CreatedOnToolsVersion = 9.1; - ProvisioningStyle = Manual; + ProvisioningStyle = Automatic; SystemCapabilities = { com.apple.BackgroundModes = { enabled = 1; @@ -689,7 +655,6 @@ files = ( 2E1D20071FAF0AE600F4405D /* LaunchScreen.storyboard in Resources */, 2F143A72217F7DA900B3E38A /* Stickers.bundle in Resources */, - 6E616DA020AB3435002CB8BE /* LICENSE.md in Resources */, 2F1B0DD321E1B38100139CB1 /* ring.caf in Resources */, 2F143A70217F7DA900B3E38A /* Emoj.plist in Resources */, 2E1D20041FAF0AE600F4405D /* Assets.xcassets in Resources */, @@ -705,6 +670,55 @@ }; /* End PBXResourcesBuildPhase section */ +/* Begin PBXShellScriptBuildPhase section */ + 125431A15AF9FAE394C0609A /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-WildFireChat/Pods-WildFireChat-frameworks.sh", + "${BUILT_PRODUCTS_DIR}/WFChatClient/WFChatClient.framework", + "${BUILT_PRODUCTS_DIR}/WFChatUIKit/WFChatUIKit.framework", + "${PODS_ROOT}/../../wfuikit/WFChatUIKit/AVEngine/GoogleWebRTC/Frameworks/frameworks/WebRTC.framework", + "${PODS_ROOT}/../../wfuikit/WFChatUIKit/AVEngine/WFAVEngineKit.framework", + ); + name = "[CP] Embed Pods Frameworks"; + outputPaths = ( + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/WFChatClient.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/WFChatUIKit.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/WebRTC.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/WFAVEngineKit.framework", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-WildFireChat/Pods-WildFireChat-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; + A35FD823BEB204251F158C61 /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-WildFireChat-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + /* Begin PBXSourcesBuildPhase section */ 2E1D1FF31FAF0AE600F4405D /* Sources */ = { isa = PBXSourcesBuildPhase; @@ -885,13 +899,14 @@ }; 2E1D200E1FAF0AE600F4405D /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = BD75A85E3A5B064156463D7B /* Pods-WildFireChat.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; CODE_SIGN_ENTITLEMENTS = WildFireChat/WildFireChat.entitlements; - CODE_SIGN_IDENTITY = "iPhone Distribution"; - CODE_SIGN_STYLE = Manual; - DEVELOPMENT_TEAM = ZTJABWRJ5T; + CODE_SIGN_IDENTITY = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = XQ9YLTYXWA; ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", @@ -905,25 +920,25 @@ INFOPLIST_FILE = WildFireChat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_BUNDLE_IDENTIFIER = cn.wildfirechat.messanger; + PRODUCT_BUNDLE_IDENTIFIER = com.app.wildfirechat; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; - PROVISIONING_PROFILE_SPECIFIER = wildfirechat_distribution; + PROVISIONING_PROFILE_SPECIFIER = ""; TARGETED_DEVICE_FAMILY = 1; }; name = Debug; }; 2E1D200F1FAF0AE600F4405D /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = F7251BFDCF08A4943E07D265 /* Pods-WildFireChat.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; CODE_SIGN_ENTITLEMENTS = WildFireChat/WildFireChat.entitlements; CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; - CODE_SIGN_STYLE = Manual; - DEVELOPMENT_TEAM = ZTJABWRJ5T; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = XQ9YLTYXWA; ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", @@ -937,11 +952,10 @@ INFOPLIST_FILE = WildFireChat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_BUNDLE_IDENTIFIER = cn.wildfirechat.messanger; + PRODUCT_BUNDLE_IDENTIFIER = com.app.wildfirechat; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; - PROVISIONING_PROFILE_SPECIFIER = wildfirechat_distribution; + PROVISIONING_PROFILE_SPECIFIER = ""; TARGETED_DEVICE_FAMILY = 1; }; name = Release; diff --git a/wfchat/WildFireChat.xcworkspace/contents.xcworkspacedata b/wfchat/WildFireChat.xcworkspace/contents.xcworkspacedata new file mode 100644 index 000000000..916beb593 --- /dev/null +++ b/wfchat/WildFireChat.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,10 @@ + + + + + + + diff --git a/wfchat/WildFireChat.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/wfchat/WildFireChat.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 000000000..18d981003 --- /dev/null +++ b/wfchat/WildFireChat.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/wfclient/WFChatClient.podspec b/wfclient/WFChatClient.podspec new file mode 100644 index 000000000..c76e9cdd6 --- /dev/null +++ b/wfclient/WFChatClient.podspec @@ -0,0 +1,47 @@ +Pod::Spec.new do |s| + s.name = 'WFChatClient' + s.version = '1.0' + s.summary = 'IM的通讯能力库。' + s.description = <<-DESC + ChatClient提供IM能力,另外附加群组关系托管,用户信息托管和好友关系托管,只提供能力,不包括UI界面。 + DESC + + s.homepage = 'https://github.com/wildfirechat/ios-chat' + s.license = { :type => 'MIT', :file => '../LICENSE' } + s.author = { 'dklinzh' => 'linzhdk@gmail.com' } + s.source = { :git => 'https://github.com/wildfirechat/ios-chat.git', :tag => s.version.to_s } + + s.requires_arc = true + s.swift_version = '5.0' + s.ios.deployment_target = '8.0' + + s.source_files = 'WFChatClient/*.h' + s.frameworks = 'CoreTelephony' + s.libraries = 'z', 'c++', 'resolv' + + s.subspec 'Proto' do |ss| + ss.vendored_frameworks = 'WFChatClient/Proto/**/*.framework' + end + + s.subspec 'Messages' do |ss| + ss.source_files = 'WFChatClient/Messages/**/*.{h,m}' + end + + s.subspec 'Model' do |ss| + ss.source_files = 'WFChatClient/Model/**/*.{h,m}' + end + + s.subspec 'Utility' do |ss| + ss.source_files = 'WFChatClient/Utility/**/*.{h,m}' + end + + s.subspec 'Client' do |ss| + ss.source_files = 'WFChatClient/Client/**/*.{h,m,mm}' + end + + s.subspec 'amr' do |ss| + ss.source_files = 'WFChatClient/amr/**/*.{h,c,mm}' + ss.vendored_libraries = 'WFChatClient/amr/**/*.a' + end + +end \ No newline at end of file diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec new file mode 100644 index 000000000..e6c94ab47 --- /dev/null +++ b/wfuikit/WFChatUIKit.podspec @@ -0,0 +1,151 @@ +Pod::Spec.new do |s| + s.name = 'WFChatUIKit' + s.version = '1.0' + s.summary = 'IIM的UI控件库,依赖于chatclient。' + s.description = <<-DESC + ChatUIKit提供常用的UI界面,客户可以直接使用ChatUIKit的UI来进行二次开发。 + DESC + + s.homepage = 'https://github.com/wildfirechat/ios-chat' + s.license = { :type => 'MIT', :file => '../LICENSE' } + s.author = { 'dklinzh' => 'linzhdk@gmail.com' } + s.source = { :git => 'https://github.com/wildfirechat/ios-chat.git', :tag => s.version.to_s } + + s.requires_arc = true + s.swift_version = '5.0' + s.ios.deployment_target = '8.0' + + s.dependency 'WFChatClient' + s.prefix_header_file = 'WFChatUIKit/Predefine.h' + s.source_files = 'WFChatUIKit/*.{h,m}' + s.resources = 'WFChatUIKit/Resources/*.{xib,bundle,plist,xcassets}' + + s.subspec 'AVEngine' do |ss| + ss.vendored_frameworks = 'WFChatUIKit/AVEngine/**/*.framework' + end + + s.subspec 'Channel' do |ss| + ss.source_files = 'WFChatUIKit/Channel/**/*.{h,m}' + end + + s.subspec 'Voip' do |ss| + ss.source_files = 'WFChatUIKit/Voip/**/*.{h,m}' + end + + s.subspec 'SelectMentionVC' do |ss| + ss.source_files = 'WFChatUIKit/SelectMentionVC/**/*.{h,m}' + end + + s.subspec 'AddFriend' do |ss| + ss.source_files = 'WFChatUIKit/AddFriend/**/*.{h,m}' + end + + s.subspec 'Category' do |ss| + ss.source_files = 'WFChatUIKit/Category/**/*.{h,m}' + end + + s.subspec 'CommonVC' do |ss| + ss.source_files = 'WFChatUIKit/CommonVC/**/*.{h,m}' + end + + s.subspec 'Contacts' do |ss| + ss.source_files = 'WFChatUIKit/Contacts/**/*.{h,m}' + end + + s.subspec 'ConversationList' do |ss| + ss.source_files = 'WFChatUIKit/ConversationList/**/*.{h,m}' + end + + s.subspec 'ConversationSetting' do |ss| + ss.source_files = 'WFChatUIKit/ConversationSetting/**/*.{h,m}' + end + + s.subspec 'CreateGroup' do |ss| + ss.source_files = 'WFChatUIKit/CreateGroup/**/*.{h,m}' + end + + s.subspec 'ForwardMessage' do |ss| + ss.source_files = 'WFChatUIKit/ForwardMessage/**/*.{h,m}' + end + + s.subspec 'FriendRequest' do |ss| + ss.source_files = 'WFChatUIKit/FriendRequest/**/*.{h,m}' + end + + s.subspec 'Group' do |ss| + ss.source_files = 'WFChatUIKit/Group/**/*.{h,m}' + end + + s.subspec 'Me' do |ss| + ss.source_files = 'WFChatUIKit/Me/**/*.{h,m}' + end + + s.subspec 'MessageList' do |ss| + ss.source_files = 'WFChatUIKit/MessageList/**/*.{h,m}' + end + + s.subspec 'Utilities' do |ss| + ss.source_files = 'WFChatUIKit/Utilities/**/*.{h,m}' + end + + s.subspec 'Vendor' do |ss| + + ss.subspec 'ChatInputBar' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/ChatInputBar/**/*.{h,m}' + end + + ss.subspec 'CCHMapClusterController' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.{h,m}' + end + + ss.subspec 'Pinyin' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/Pinyin/**/*.{h,c}' + end + + ss.subspec 'VideoPlayerKit' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.{h,m}' + end + + ss.subspec 'KZSmallVideoRecorder' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.{h,m}' + end + + ss.subspec 'SDPhotoBrowser' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.{h,m}' + end + + ss.subspec 'KxMenu' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/KxMenu/**/*.{h,m}' + end + + ss.subspec 'AFNetworking' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.{h,m}' + end + + ss.subspec 'MBProgressHUD' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.{h,m}' + end + + ss.subspec 'SDRefeshView' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.{h,m}' + end + + ss.subspec 'UITextViewPlaceholder' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.{h,m}' + end + + ss.subspec 'SDWebImage' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.{h,m}' + end + + ss.subspec 'TYAlertController' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.{h,m}' + end + + ss.subspec 'YLGIFImage' do |sss| + sss.source_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.{h,m}' + end + + end + +end \ No newline at end of file From 9c1839e3e5959aca3beb1c9a3ea1f5539ee226e9 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Mon, 22 Jul 2019 15:13:27 +0800 Subject: [PATCH 03/10] build(pods): fix build errors and remove the duplicated references of framework --- wfchat/Podfile.lock | 7 ++-- wfchat/WildFireChat.xcodeproj/project.pbxproj | 36 ++++--------------- .../xcshareddata/WorkspaceSettings.xcsettings | 5 +++ wfclient/WFChatClient.podspec | 5 +-- wfuikit/WFChatUIKit.podspec | 16 ++++++--- 5 files changed, 29 insertions(+), 40 deletions(-) create mode 100644 wfchat/WildFireChat.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock index 215e14077..e0931a4e3 100644 --- a/wfchat/Podfile.lock +++ b/wfchat/Podfile.lock @@ -110,6 +110,7 @@ PODS: - WFChatClient - WFChatUIKit/Voip (1.0): - WFChatClient + - WFChatUIKit/AVEngine DEPENDENCIES: - WFChatClient (from `../wfclient`) @@ -122,9 +123,9 @@ EXTERNAL SOURCES: :path: "../wfuikit" SPEC CHECKSUMS: - WFChatClient: 8195d6eb2afc32b8d37f15980d8e176ecf0814cb - WFChatUIKit: 995a75f36d80f0c6f0d8a3c5b99304d3c3bad3fb + WFChatClient: 7b869b8c794d5b23f75144e577c09e6a99fb6530 + WFChatUIKit: a118d1735cac5b4d0b25ea8880677f9263242118 PODFILE CHECKSUM: b3a937c88865791df4f5e2f0cef525a0429d5067 -COCOAPODS: 1.7.4 +COCOAPODS: 1.7.5 diff --git a/wfchat/WildFireChat.xcodeproj/project.pbxproj b/wfchat/WildFireChat.xcodeproj/project.pbxproj index ed7558590..f2c033a11 100644 --- a/wfchat/WildFireChat.xcodeproj/project.pbxproj +++ b/wfchat/WildFireChat.xcodeproj/project.pbxproj @@ -15,16 +15,12 @@ 2E1D20B01FAF125D00F4405D /* WFCBaseTabBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20AF1FAF125D00F4405D /* WFCBaseTabBarController.m */; }; 2E1D20D41FAF127100F4405D /* WFCConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20B11FAF127100F4405D /* WFCConfig.m */; }; 2E1D20D91FAF127100F4405D /* DiscoverViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2E1D20BE1FAF127100F4405D /* DiscoverViewController.m */; }; - 2F143A70217F7DA900B3E38A /* Emoj.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A6D217F7DA900B3E38A /* Emoj.plist */; }; - 2F143A72217F7DA900B3E38A /* Stickers.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A6F217F7DA900B3E38A /* Stickers.bundle */; }; - 2F143A81217F86BA00B3E38A /* WFChatUIKit.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2F143A80217F86B900B3E38A /* WFChatUIKit.xcassets */; }; 2F1B0DCF21E19AF400139CB1 /* UserNotificationsUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCC21E19AF400139CB1 /* UserNotificationsUI.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; 2F1B0DD021E19AF400139CB1 /* NotificationCenter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCD21E19AF400139CB1 /* NotificationCenter.framework */; }; 2F1B0DD121E19AF400139CB1 /* UserNotifications.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DCE21E19AF400139CB1 /* UserNotifications.framework */; }; 2F1B0DD321E1B38100139CB1 /* ring.caf in Resources */ = {isa = PBXBuildFile; fileRef = 2F1B0DD221E1B38100139CB1 /* ring.caf */; }; 2F1B0DD521E1E29400139CB1 /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DD421E1E29400139CB1 /* AudioToolbox.framework */; }; 2F1B0DEE21E2161E00139CB1 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2F1B0DED21E2161E00139CB1 /* CoreTelephony.framework */; }; - 2F25F747219ECFD100FFABF9 /* WFCUShareMessageView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */; }; 2F623A5022DCBD3E00CB3C65 /* Album.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2F623A4F22DCBD3E00CB3C65 /* Album.xcassets */; }; 2F7268F921F7136600E05F9C /* WFCPrivacyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2F7268F821F7136600E05F9C /* WFCPrivacyViewController.m */; }; 2F7268FD21F714C900E05F9C /* UILabel+YBAttributeTextTapAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 2F7268FB21F714C900E05F9C /* UILabel+YBAttributeTextTapAction.m */; }; @@ -55,8 +51,6 @@ 2FF07F5F21F82E7200A78A62 /* WFCSecurityTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2FF07F5521F82E7200A78A62 /* WFCSecurityTableViewController.m */; }; 9051774C2243CD830020A2AC /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774B2243CD830020A2AC /* SystemConfiguration.framework */; }; 9051774E2243CD8D0020A2AC /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774D2243CD8D0020A2AC /* Security.framework */; }; - 905177502243CD9A0020A2AC /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 9051774F2243CD9A0020A2AC /* libz.tbd */; }; - 905177522243CDA60020A2AC /* libc++.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 905177512243CDA60020A2AC /* libc++.tbd */; }; 905177542243CEA30020A2AC /* Bugly.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 905177532243CEA30020A2AC /* Bugly.framework */; }; 9085427B2229FF160009713D /* StyleDIY.m in Sources */ = {isa = PBXBuildFile; fileRef = 908542792229FF160009713D /* StyleDIY.m */; }; 9085427E222A00430009713D /* DIYScanViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9085427D222A00430009713D /* DIYScanViewController.m */; }; @@ -134,16 +128,12 @@ 2F143A50217F607300B3E38A /* AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworking.h; sourceTree = ""; }; 2F143A53217F607300B3E38A /* AFHTTPSessionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPSessionManager.h; sourceTree = ""; }; 2F143A5C217F60B600B3E38A /* MBProgressHUD.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MBProgressHUD.h; sourceTree = ""; }; - 2F143A6D217F7DA900B3E38A /* Emoj.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Emoj.plist; path = Frameworks/Emoj.plist; sourceTree = SOURCE_ROOT; }; - 2F143A6F217F7DA900B3E38A /* Stickers.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = Stickers.bundle; path = Frameworks/Stickers.bundle; sourceTree = SOURCE_ROOT; }; - 2F143A80217F86B900B3E38A /* WFChatUIKit.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = WFChatUIKit.xcassets; path = Frameworks/WFChatUIKit.xcassets; sourceTree = SOURCE_ROOT; }; 2F1B0DCC21E19AF400139CB1 /* UserNotificationsUI.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UserNotificationsUI.framework; path = System/Library/Frameworks/UserNotificationsUI.framework; sourceTree = SDKROOT; }; 2F1B0DCD21E19AF400139CB1 /* NotificationCenter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = NotificationCenter.framework; path = System/Library/Frameworks/NotificationCenter.framework; sourceTree = SDKROOT; }; 2F1B0DCE21E19AF400139CB1 /* UserNotifications.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UserNotifications.framework; path = System/Library/Frameworks/UserNotifications.framework; sourceTree = SDKROOT; }; 2F1B0DD221E1B38100139CB1 /* ring.caf */ = {isa = PBXFileReference; lastKnownFileType = file; path = ring.caf; sourceTree = ""; }; 2F1B0DD421E1E29400139CB1 /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; }; 2F1B0DED21E2161E00139CB1 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; }; - 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; name = WFCUShareMessageView.xib; path = Frameworks/WFCUShareMessageView.xib; sourceTree = SOURCE_ROOT; }; 2F623A4F22DCBD3E00CB3C65 /* Album.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Album.xcassets; sourceTree = ""; }; 2F7268F721F7136600E05F9C /* WFCPrivacyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WFCPrivacyViewController.h; sourceTree = ""; }; 2F7268F821F7136600E05F9C /* WFCPrivacyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCPrivacyViewController.m; sourceTree = ""; }; @@ -200,8 +190,6 @@ 2FF07F5521F82E7200A78A62 /* WFCSecurityTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WFCSecurityTableViewController.m; sourceTree = ""; }; 9051774B2243CD830020A2AC /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; 9051774D2243CD8D0020A2AC /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; - 9051774F2243CD9A0020A2AC /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; - 905177512243CDA60020A2AC /* libc++.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; }; 905177532243CEA30020A2AC /* Bugly.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Bugly.framework; path = WildFireChat/Bugly.framework; sourceTree = SOURCE_ROOT; }; 908542792229FF160009713D /* StyleDIY.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = StyleDIY.m; sourceTree = ""; }; 9085427A2229FF160009713D /* StyleDIY.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StyleDIY.h; sourceTree = ""; }; @@ -232,8 +220,6 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 905177522243CDA60020A2AC /* libc++.tbd in Frameworks */, - 905177502243CD9A0020A2AC /* libz.tbd in Frameworks */, 905177542243CEA30020A2AC /* Bugly.framework in Frameworks */, 9051774E2243CD8D0020A2AC /* Security.framework in Frameworks */, 9051774C2243CD830020A2AC /* SystemConfiguration.framework in Frameworks */, @@ -307,8 +293,6 @@ 2EAC88E61FB0A0D6004B34D1 /* Frameworks */ = { isa = PBXGroup; children = ( - 905177512243CDA60020A2AC /* libc++.tbd */, - 9051774F2243CD9A0020A2AC /* libz.tbd */, 9051774D2243CD8D0020A2AC /* Security.framework */, 9051774B2243CD830020A2AC /* SystemConfiguration.framework */, 2F1B0DED21E2161E00139CB1 /* CoreTelephony.framework */, @@ -316,11 +300,7 @@ 2F1B0DCD21E19AF400139CB1 /* NotificationCenter.framework */, 2F1B0DCE21E19AF400139CB1 /* UserNotifications.framework */, 2F1B0DCC21E19AF400139CB1 /* UserNotificationsUI.framework */, - 2F143A80217F86B900B3E38A /* WFChatUIKit.xcassets */, 905177532243CEA30020A2AC /* Bugly.framework */, - 2F143A6D217F7DA900B3E38A /* Emoj.plist */, - 2F25F746219ECFD100FFABF9 /* WFCUShareMessageView.xib */, - 2F143A6F217F7DA900B3E38A /* Stickers.bundle */, 20595D62708F726D5A46BAD2 /* Pods_WildFireChat.framework */, ); path = Frameworks; @@ -654,17 +634,13 @@ buildActionMask = 2147483647; files = ( 2E1D20071FAF0AE600F4405D /* LaunchScreen.storyboard in Resources */, - 2F143A72217F7DA900B3E38A /* Stickers.bundle in Resources */, 2F1B0DD321E1B38100139CB1 /* ring.caf in Resources */, - 2F143A70217F7DA900B3E38A /* Emoj.plist in Resources */, 2E1D20041FAF0AE600F4405D /* Assets.xcassets in Resources */, 2E1D20021FAF0AE600F4405D /* Main.storyboard in Resources */, 2F94FB8B22291577005BD461 /* CodeScan.bundle in Resources */, 2F623A5022DCBD3E00CB3C65 /* Album.xcassets in Resources */, 90C1D911208C12A900E923F4 /* foreman.mp4 in Resources */, - 2F143A81217F86BA00B3E38A /* WFChatUIKit.xcassets in Resources */, 90C1D912208C12A900E923F4 /* ring.mp3 in Resources */, - 2F25F747219ECFD100FFABF9 /* WFCUShareMessageView.xib in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -839,7 +815,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; @@ -890,7 +866,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; VALIDATE_PRODUCT = YES; @@ -906,7 +882,7 @@ CODE_SIGN_ENTITLEMENTS = WildFireChat/WildFireChat.entitlements; CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = XQ9YLTYXWA; + DEVELOPMENT_TEAM = ""; ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", @@ -920,7 +896,7 @@ INFOPLIST_FILE = WildFireChat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - PRODUCT_BUNDLE_IDENTIFIER = com.app.wildfirechat; + PRODUCT_BUNDLE_IDENTIFIER = cn.wildfirechat.messanger; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -938,7 +914,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = XQ9YLTYXWA; + DEVELOPMENT_TEAM = ""; ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", @@ -952,7 +928,7 @@ INFOPLIST_FILE = WildFireChat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - PRODUCT_BUNDLE_IDENTIFIER = com.app.wildfirechat; + PRODUCT_BUNDLE_IDENTIFIER = cn.wildfirechat.messanger; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; PROVISIONING_PROFILE_SPECIFIER = ""; diff --git a/wfchat/WildFireChat.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/wfchat/WildFireChat.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 000000000..0c67376eb --- /dev/null +++ b/wfchat/WildFireChat.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,5 @@ + + + + + diff --git a/wfclient/WFChatClient.podspec b/wfclient/WFChatClient.podspec index c76e9cdd6..b43712ed4 100644 --- a/wfclient/WFChatClient.podspec +++ b/wfclient/WFChatClient.podspec @@ -12,7 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/wildfirechat/ios-chat.git', :tag => s.version.to_s } s.requires_arc = true - s.swift_version = '5.0' s.ios.deployment_target = '8.0' s.source_files = 'WFChatClient/*.h' @@ -36,12 +35,14 @@ Pod::Spec.new do |s| end s.subspec 'Client' do |ss| + ss.private_header_files = 'WFChatClient/Client/app_callback.h' ss.source_files = 'WFChatClient/Client/**/*.{h,m,mm}' end s.subspec 'amr' do |ss| + ss.private_header_files = 'WFChatClient/amr/*.h' ss.source_files = 'WFChatClient/amr/**/*.{h,c,mm}' ss.vendored_libraries = 'WFChatClient/amr/**/*.a' end -end \ No newline at end of file +end diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index e6c94ab47..9c124ae3a 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -12,16 +12,19 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/wildfirechat/ios-chat.git', :tag => s.version.to_s } s.requires_arc = true - s.swift_version = '5.0' s.ios.deployment_target = '8.0' - s.dependency 'WFChatClient' s.prefix_header_file = 'WFChatUIKit/Predefine.h' + s.private_header_files = 'WFChatUIKit/Predefine.h' s.source_files = 'WFChatUIKit/*.{h,m}' - s.resources = 'WFChatUIKit/Resources/*.{xib,bundle,plist,xcassets}' - + s.resources = 'WFChatUIKit/Resources/*.{xcassets}' + s.dependency 'WFChatClient' + s.subspec 'AVEngine' do |ss| ss.vendored_frameworks = 'WFChatUIKit/AVEngine/**/*.framework' + ss.pod_target_xcconfig = { + 'OTHER_LDFLAGS' => '$(inherited) -framework WFAVEngineKit -framework WebRTC' + } end s.subspec 'Channel' do |ss| @@ -29,6 +32,7 @@ Pod::Spec.new do |s| end s.subspec 'Voip' do |ss| + ss.dependency 'WFChatUIKit/AVEngine' ss.source_files = 'WFChatUIKit/Voip/**/*.{h,m}' end @@ -66,6 +70,7 @@ Pod::Spec.new do |s| s.subspec 'ForwardMessage' do |ss| ss.source_files = 'WFChatUIKit/ForwardMessage/**/*.{h,m}' + ss.resources = 'WFChatUIKit/Resources/WFCUShareMessageView.xib' end s.subspec 'FriendRequest' do |ss| @@ -92,6 +97,7 @@ Pod::Spec.new do |s| ss.subspec 'ChatInputBar' do |sss| sss.source_files = 'WFChatUIKit/Vendor/ChatInputBar/**/*.{h,m}' + sss.resources = 'WFChatUIKit/Resources/Stickers.bundle', 'WFChatUIKit/Resources/Emoj.plist' end ss.subspec 'CCHMapClusterController' do |sss| @@ -148,4 +154,4 @@ Pod::Spec.new do |s| end -end \ No newline at end of file +end From 468d57d67f4c958e7aeb9334da8aacab8db47996 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Tue, 23 Jul 2019 06:00:15 +0800 Subject: [PATCH 04/10] feat: add extension `+[UIImage wf_imageNamed:]` to prefix header for loading image resources in pods project --- wfchat/Podfile | 2 ++ wfchat/Podfile.lock | 4 ++-- wfuikit/WFChatUIKit.podspec | 5 +++-- wfuikit/WFChatUIKit/UIImage+Pods.h | 18 ++++++++++++++++++ wfuikit/WFChatUIKit/UIImage+Pods.m | 20 ++++++++++++++++++++ 5 files changed, 45 insertions(+), 4 deletions(-) create mode 100644 wfuikit/WFChatUIKit/UIImage+Pods.h create mode 100644 wfuikit/WFChatUIKit/UIImage+Pods.m diff --git a/wfchat/Podfile b/wfchat/Podfile index d241056f0..195dd1a86 100644 --- a/wfchat/Podfile +++ b/wfchat/Podfile @@ -4,6 +4,8 @@ platform :ios, '8.0' use_frameworks! +install! 'cocoapods', :generate_multiple_pod_projects => true + target 'WildFireChat' do pod 'WFChatClient', :path => '../wfclient' diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock index e0931a4e3..15a7589a4 100644 --- a/wfchat/Podfile.lock +++ b/wfchat/Podfile.lock @@ -124,8 +124,8 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: WFChatClient: 7b869b8c794d5b23f75144e577c09e6a99fb6530 - WFChatUIKit: a118d1735cac5b4d0b25ea8880677f9263242118 + WFChatUIKit: a533f09b8d413273afdb618caeb880ffa3fdc0e3 -PODFILE CHECKSUM: b3a937c88865791df4f5e2f0cef525a0429d5067 +PODFILE CHECKSUM: c34f7b98694e66489f75ff12ea6f5f7b7edf7bf7 COCOAPODS: 1.7.5 diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index 9c124ae3a..a6085c218 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -14,8 +14,9 @@ Pod::Spec.new do |s| s.requires_arc = true s.ios.deployment_target = '8.0' + s.prefix_header_contents = '#ifdef __OBJC__', '#import ', '#endif' s.prefix_header_file = 'WFChatUIKit/Predefine.h' - s.private_header_files = 'WFChatUIKit/Predefine.h' + s.exclude_files = 'WFChatUIKit/Predefine.h' s.source_files = 'WFChatUIKit/*.{h,m}' s.resources = 'WFChatUIKit/Resources/*.{xcassets}' s.dependency 'WFChatClient' @@ -23,7 +24,7 @@ Pod::Spec.new do |s| s.subspec 'AVEngine' do |ss| ss.vendored_frameworks = 'WFChatUIKit/AVEngine/**/*.framework' ss.pod_target_xcconfig = { - 'OTHER_LDFLAGS' => '$(inherited) -framework WFAVEngineKit -framework WebRTC' + 'OTHER_LDFLAGS' => '$(inherited) -ObjC -framework WFAVEngineKit -framework WebRTC' } end diff --git a/wfuikit/WFChatUIKit/UIImage+Pods.h b/wfuikit/WFChatUIKit/UIImage+Pods.h new file mode 100644 index 000000000..f8f2b8e61 --- /dev/null +++ b/wfuikit/WFChatUIKit/UIImage+Pods.h @@ -0,0 +1,18 @@ +// +// UIImage+Pods.h +// WFChatUIKit +// +// Created by dklinzh on 2019/7/22. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +@interface UIImage (Pods) + ++ (nullable instancetype)wf_imageNamed:(NSString *)name; + +@end + +NS_ASSUME_NONNULL_END diff --git a/wfuikit/WFChatUIKit/UIImage+Pods.m b/wfuikit/WFChatUIKit/UIImage+Pods.m new file mode 100644 index 000000000..e7814bae2 --- /dev/null +++ b/wfuikit/WFChatUIKit/UIImage+Pods.m @@ -0,0 +1,20 @@ +// +// UIImage+Pods.m +// WFChatUIKit +// +// Created by dklinzh on 2019/7/22. +// + +#import "UIImage+Pods.h" + +@implementation UIImage (Pods) + ++ (instancetype)wf_imageNamed:(NSString *)name { +#ifdef COCOAPODS + return [self imageNamed:name inBundle:[NSBundle bundleForClass:self] compatibleWithTraitCollection:nil]; +#else + return [self imageNamed:name]; +#endif +} + +@end From 8a4054f64d27a5ad8fbc9831c7d9b3aee8351530 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Tue, 23 Jul 2019 15:53:01 +0800 Subject: [PATCH 05/10] fix(pods): add UIKit extensions to load image, xib resources in the bundle of Pods target instead of main bundle --- wfchat/Podfile | 2 +- wfchat/Podfile.lock | 4 +- wfuikit/WFChatUIKit.podspec | 2 +- .../WFCUAddFriendViewController.m | 2 +- wfuikit/WFChatUIKit/Category/TabbarButton.m | 2 +- .../{UIImage+Pods.h => Category/UIKit+Pods.h} | 16 ++++- wfuikit/WFChatUIKit/Category/UIKit+Pods.m | 57 +++++++++++++++++ wfuikit/WFChatUIKit/Category/UITabBar+badge.m | 2 +- .../WFCUChannelProfileViewController.m | 2 +- .../Channel/WFCUChannelTableViewCell.m | 2 +- .../WFCUFavChannelTableViewController.m | 2 +- .../Channel/WFCUSearchChannelViewController.m | 2 +- .../CommonVC/WFCUGroupMemberTableViewCell.m | 8 +-- .../CommonVC/WFCUGroupTableViewCell.m | 2 +- .../CommonVC/WFCUProfileTableViewController.m | 2 +- .../Cell/WFCUContactSelectTableViewCell.m | 10 +-- .../Contacts/Cell/WFCUContactTableViewCell.m | 2 +- .../WFCUContactListViewController.m | 12 ++-- .../Cell/WFCUConversationTableViewCell.m | 14 ++-- .../WFCUConversationSearchTableViewCell.m | 2 +- .../SearchCell/WFCUSearchGroupTableViewCell.m | 2 +- ...FCUConversationSearchTableViewController.m | 6 +- .../WFCUConversationTableViewController.m | 12 ++-- .../Cell/WFCUConversationSettingMemberCell.m | 4 +- .../ManagerTableViewController.m | 4 +- .../WFCUConversationSettingViewController.m | 10 +-- .../WFCUCreateChannelViewController.m | 2 +- .../WFCUCreateGroupViewController.m | 6 +- .../ForwardMessage/WFCUForwardMessageCell.m | 6 +- .../WFCUForwardViewController.m | 2 +- .../ForwardMessage/WFCUShareMessageView.m | 6 +- .../Cell/WFCUFriendRequestTableViewCell.m | 2 +- .../Me/WFCUMyPortraitViewController.m | 4 +- .../Me/WFCUMyProfileTableViewController.m | 4 +- .../MessageList/Cell/WFCUCallSummaryCell.m | 4 +- .../MessageList/Cell/WFCUFileCell.m | 2 +- .../MessageList/Cell/WFCUMessageCell.m | 10 +-- .../MessageList/Cell/WFCUVideoCell.m | 2 +- .../MessageList/Cell/WFCUVoiceCell.m | 6 +- .../WFCUMessageListViewController.m | 6 +- wfuikit/WFChatUIKit/UIImage+Pods.m | 20 ------ .../ChatInputBar/FaceBoard/WFCUFaceBoard.m | 8 +-- .../Vendor/ChatInputBar/WFCUChatInputBar.m | 14 ++-- .../ChatInputBar/WFCULocationViewController.m | 4 +- .../Vendor/ChatInputBar/WFCUPluginBoardView.m | 18 +++--- .../WFCUSelectFileViewController.m | 8 +-- .../WFCUSelectedFileCollectionViewCell.m | 2 +- .../Vendor/ChatInputBar/WFCUVoiceRecordView.m | 8 +-- .../KZSmallVideoRecorder/KZVideoSupport.m | 2 +- .../Vendor/SDRefeshView/SDRefreshView.m | 2 +- .../Vendor/SDWebImage/UIImageView+WebCache.h | 2 +- .../Vendor/VideoPlayerKit/AirplayActiveView.m | 2 +- .../Vendor/VideoPlayerKit/VideoPlayerKit.m | 8 +-- .../Vendor/VideoPlayerKit/VideoPlayerView.m | 10 +-- wfuikit/WFChatUIKit/Voip/WFCUFloatingWindow.m | 4 +- .../Voip/WFCUVideoViewController.m | 64 +++++++++---------- 56 files changed, 237 insertions(+), 186 deletions(-) rename wfuikit/WFChatUIKit/{UIImage+Pods.h => Category/UIKit+Pods.h} (51%) create mode 100644 wfuikit/WFChatUIKit/Category/UIKit+Pods.m delete mode 100644 wfuikit/WFChatUIKit/UIImage+Pods.m diff --git a/wfchat/Podfile b/wfchat/Podfile index 195dd1a86..cf34f0eaa 100644 --- a/wfchat/Podfile +++ b/wfchat/Podfile @@ -4,7 +4,7 @@ platform :ios, '8.0' use_frameworks! -install! 'cocoapods', :generate_multiple_pod_projects => true +#install! 'cocoapods', :generate_multiple_pod_projects => true target 'WildFireChat' do diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock index 15a7589a4..69358b5b3 100644 --- a/wfchat/Podfile.lock +++ b/wfchat/Podfile.lock @@ -124,8 +124,8 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: WFChatClient: 7b869b8c794d5b23f75144e577c09e6a99fb6530 - WFChatUIKit: a533f09b8d413273afdb618caeb880ffa3fdc0e3 + WFChatUIKit: cd315dbcce34a5ac2541e81eb55c77a1b2508c9a -PODFILE CHECKSUM: c34f7b98694e66489f75ff12ea6f5f7b7edf7bf7 +PODFILE CHECKSUM: 2f1c7b0c5e5bb85465ace5c46b6316b9c5b1b2dd COCOAPODS: 1.7.5 diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index a6085c218..653f77acb 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -14,7 +14,7 @@ Pod::Spec.new do |s| s.requires_arc = true s.ios.deployment_target = '8.0' - s.prefix_header_contents = '#ifdef __OBJC__', '#import ', '#endif' + s.prefix_header_contents = '#ifdef __OBJC__', '#import ', '#endif' s.prefix_header_file = 'WFChatUIKit/Predefine.h' s.exclude_files = 'WFChatUIKit/Predefine.h' s.source_files = 'WFChatUIKit/*.{h,m}' diff --git a/wfuikit/WFChatUIKit/AddFriend/ViewController/WFCUAddFriendViewController.m b/wfuikit/WFChatUIKit/AddFriend/ViewController/WFCUAddFriendViewController.m index c6eb900bc..d3f607d16 100644 --- a/wfuikit/WFChatUIKit/AddFriend/ViewController/WFCUAddFriendViewController.m +++ b/wfuikit/WFChatUIKit/AddFriend/ViewController/WFCUAddFriendViewController.m @@ -102,7 +102,7 @@ -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NS } WFCCUserInfo *userInfo = self.searchList[indexPath.row]; [cell.textLabel setText:userInfo.displayName]; - [cell.imageView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [cell.imageView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; cell.userInteractionEnabled = YES; return cell; diff --git a/wfuikit/WFChatUIKit/Category/TabbarButton.m b/wfuikit/WFChatUIKit/Category/TabbarButton.m index 433fd8965..afd7379b7 100644 --- a/wfuikit/WFChatUIKit/Category/TabbarButton.m +++ b/wfuikit/WFChatUIKit/Category/TabbarButton.m @@ -46,7 +46,7 @@ - (NSMutableArray *)images if (_images == nil) { _images = [NSMutableArray array]; for (int i = 1; i < 9; i++) { - UIImage *image = [UIImage imageNamed:[NSString stringWithFormat:@"%d", i]]; + UIImage *image = [UIImage wf_imageNamed:[NSString stringWithFormat:@"%d", i]]; [_images addObject:image]; } } diff --git a/wfuikit/WFChatUIKit/UIImage+Pods.h b/wfuikit/WFChatUIKit/Category/UIKit+Pods.h similarity index 51% rename from wfuikit/WFChatUIKit/UIImage+Pods.h rename to wfuikit/WFChatUIKit/Category/UIKit+Pods.h index f8f2b8e61..e4ea8f3c2 100644 --- a/wfuikit/WFChatUIKit/UIImage+Pods.h +++ b/wfuikit/WFChatUIKit/Category/UIKit+Pods.h @@ -1,5 +1,5 @@ // -// UIImage+Pods.h +// UIKit+Pods.h // WFChatUIKit // // Created by dklinzh on 2019/7/22. @@ -9,10 +9,24 @@ NS_ASSUME_NONNULL_BEGIN +@interface NSBundle (Pods) + ++ (instancetype)wf_bundle; + +@end + @interface UIImage (Pods) + (nullable instancetype)wf_imageNamed:(NSString *)name; @end +@interface UIView (Pods) + ++ (instancetype)wf_createViewFromNibName:(NSString *)nibName; + ++ (instancetype)wf_createViewFromNib; + +@end + NS_ASSUME_NONNULL_END diff --git a/wfuikit/WFChatUIKit/Category/UIKit+Pods.m b/wfuikit/WFChatUIKit/Category/UIKit+Pods.m new file mode 100644 index 000000000..4ec32b9ad --- /dev/null +++ b/wfuikit/WFChatUIKit/Category/UIKit+Pods.m @@ -0,0 +1,57 @@ +// +// UIKit+Pods.m +// WFChatUIKit +// +// Created by dklinzh on 2019/7/22. +// + +#import "UIKit+Pods.h" + +@interface _BundleClass : NSObject + +@end + +@implementation _BundleClass + +@end + +@implementation NSBundle (Pods) + ++ (instancetype)wf_bundle { +#ifdef COCOAPODS + return [NSBundle bundleForClass:_BundleClass.class]; +#else + return [self mainBundle]; +#endif +} + +@end + +@implementation UIImage (Pods) + ++ (instancetype)wf_imageNamed:(NSString *)name { +#ifdef COCOAPODS + return [self imageNamed:name inBundle:[NSBundle wf_bundle] compatibleWithTraitCollection:nil]; +#else + return [self imageNamed:name]; +#endif +} + +@end + +@implementation UIView (Pods) + ++ (instancetype)wf_createViewFromNibName:(NSString *)nibName { +#ifdef COCOAPODS + NSArray *nib = [[NSBundle wf_bundle] loadNibNamed:nibName owner:self options:nil]; +#else + NSArray *nib = [[NSBundle mainBundle] loadNibNamed:nibName owner:self options:nil]; +#endif + return [nib objectAtIndex:0]; +} + ++ (instancetype)wf_createViewFromNib { + return [self wf_createViewFromNibName:NSStringFromClass(self.class)]; +} + +@end diff --git a/wfuikit/WFChatUIKit/Category/UITabBar+badge.m b/wfuikit/WFChatUIKit/Category/UITabBar+badge.m index d900dba6a..0f1fe5ea8 100644 --- a/wfuikit/WFChatUIKit/Category/UITabBar+badge.m +++ b/wfuikit/WFChatUIKit/Category/UITabBar+badge.m @@ -41,7 +41,7 @@ - (void)showBadgeOnItemIndex:(int)index badgeValue:(int)badgeValue{ } if (badgeValue >= 100) { TabbarButton *btn = [[TabbarButton alloc] initWithFrame:CGRectMake(x, y, 22, 18)]; - UIImage *image = [[UIImage imageNamed:@"more_unread"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal]; + UIImage *image = [[UIImage wf_imageNamed:@"more_unread"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal]; [btn setImage:image forState:UIControlStateNormal]; [self addSubview:btn]; btn.tag = 888+index; diff --git a/wfuikit/WFChatUIKit/Channel/WFCUChannelProfileViewController.m b/wfuikit/WFChatUIKit/Channel/WFCUChannelProfileViewController.m index a2e9fd44f..0f4fb4c38 100644 --- a/wfuikit/WFChatUIKit/Channel/WFCUChannelProfileViewController.m +++ b/wfuikit/WFChatUIKit/Channel/WFCUChannelProfileViewController.m @@ -35,7 +35,7 @@ - (void)viewDidLoad { CGFloat screenWidth = [UIScreen mainScreen].bounds.size.width; self.channelPortrait = [[UIImageView alloc] initWithFrame:CGRectMake((screenWidth - portraitWidth)/2, top, portraitWidth, portraitWidth)]; - [self.channelPortrait sd_setImageWithURL:[NSURL URLWithString:self.channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.channelPortrait sd_setImageWithURL:[NSURL URLWithString:self.channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; top += portraitWidth; top += 20; diff --git a/wfuikit/WFChatUIKit/Channel/WFCUChannelTableViewCell.m b/wfuikit/WFChatUIKit/Channel/WFCUChannelTableViewCell.m index b0d58569b..6d66c6b01 100644 --- a/wfuikit/WFChatUIKit/Channel/WFCUChannelTableViewCell.m +++ b/wfuikit/WFChatUIKit/Channel/WFCUChannelTableViewCell.m @@ -51,6 +51,6 @@ - (void)setChannelInfo:(WFCCChannelInfo *)channelInfo { } else { self.name.text = [NSString stringWithFormat:@"%@", channelInfo.name]; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; } @end diff --git a/wfuikit/WFChatUIKit/Channel/WFCUFavChannelTableViewController.m b/wfuikit/WFChatUIKit/Channel/WFCUFavChannelTableViewController.m index fd14683fa..a75780f8b 100644 --- a/wfuikit/WFChatUIKit/Channel/WFCUFavChannelTableViewController.m +++ b/wfuikit/WFChatUIKit/Channel/WFCUFavChannelTableViewController.m @@ -28,7 +28,7 @@ - (void)viewDidLoad { self.title = @"我的频道"; self.tableView.tableFooterView = [[UIView alloc] initWithFrame:CGRectZero]; - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"bar_plus"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"bar_plus"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; } - (void)onRightBarBtn:(id)sender { diff --git a/wfuikit/WFChatUIKit/Channel/WFCUSearchChannelViewController.m b/wfuikit/WFChatUIKit/Channel/WFCUSearchChannelViewController.m index dca11b387..8d445dbf9 100644 --- a/wfuikit/WFChatUIKit/Channel/WFCUSearchChannelViewController.m +++ b/wfuikit/WFChatUIKit/Channel/WFCUSearchChannelViewController.m @@ -102,7 +102,7 @@ -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NS } WFCCChannelInfo *channelInfo = self.searchList[indexPath.row]; [cell.textLabel setText:channelInfo.name]; - [cell.imageView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [cell.imageView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; cell.userInteractionEnabled = YES; return cell; diff --git a/wfuikit/WFChatUIKit/CommonVC/WFCUGroupMemberTableViewCell.m b/wfuikit/WFChatUIKit/CommonVC/WFCUGroupMemberTableViewCell.m index aed8e6cae..4713a163b 100644 --- a/wfuikit/WFChatUIKit/CommonVC/WFCUGroupMemberTableViewCell.m +++ b/wfuikit/WFChatUIKit/CommonVC/WFCUGroupMemberTableViewCell.m @@ -23,7 +23,7 @@ - (void)initSubViews { if (self.isSelectable) { } - [self.portraitView setImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView setImage:[UIImage wf_imageNamed:@"PersonalChat"]]; [self.contentView addSubview:self.portraitView]; @@ -36,7 +36,7 @@ - (void)setIsSelectable:(BOOL)isSelectable { if (isSelectable) { if (self.selectView == nil) { self.selectView = [[UIImageView alloc] initWithFrame:CGRectMake([UIScreen mainScreen].bounds.size.width - 32, 8, 20, 20)]; - self.selectView.image = [UIImage imageNamed:@"multi_unselected"]; + self.selectView.image = [UIImage wf_imageNamed:@"multi_unselected"]; [self.contentView addSubview:self.selectView]; } } else { @@ -54,9 +54,9 @@ - (void)setIsSelected:(BOOL)isSelected { } if (isSelected) { - self.selectView.image = [UIImage imageNamed:@"multi_selected"]; + self.selectView.image = [UIImage wf_imageNamed:@"multi_selected"]; } else { - self.selectView.image = [UIImage imageNamed:@"multi_unselected"]; + self.selectView.image = [UIImage wf_imageNamed:@"multi_unselected"]; } } diff --git a/wfuikit/WFChatUIKit/CommonVC/WFCUGroupTableViewCell.m b/wfuikit/WFChatUIKit/CommonVC/WFCUGroupTableViewCell.m index 74f29f1fc..4fdd498ce 100644 --- a/wfuikit/WFChatUIKit/CommonVC/WFCUGroupTableViewCell.m +++ b/wfuikit/WFChatUIKit/CommonVC/WFCUGroupTableViewCell.m @@ -51,6 +51,6 @@ - (void)setGroupInfo:(WFCCGroupInfo *)groupInfo { } else { self.name.text = [NSString stringWithFormat:@"%@(%d)", groupInfo.name, (int)groupInfo.memberCount]; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; } @end diff --git a/wfuikit/WFChatUIKit/CommonVC/WFCUProfileTableViewController.m b/wfuikit/WFChatUIKit/CommonVC/WFCUProfileTableViewController.m index a3d5483be..b36db4483 100644 --- a/wfuikit/WFChatUIKit/CommonVC/WFCUProfileTableViewController.m +++ b/wfuikit/WFChatUIKit/CommonVC/WFCUProfileTableViewController.m @@ -101,7 +101,7 @@ - (void)loadData { self.portraitView.userInteractionEnabled = YES; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; NSString *alias = [[WFCCIMService sharedWFCIMService] getFriendAlias:self.userId]; if (alias.length) { diff --git a/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactSelectTableViewCell.m b/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactSelectTableViewCell.m index 68f7ca88a..27cc9d862 100644 --- a/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactSelectTableViewCell.m +++ b/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactSelectTableViewCell.m @@ -66,15 +66,15 @@ - (void)setChecked:(BOOL)checked { _checked = checked; if (self.multiSelect) { if (checked) { - self.checkImageView.image = [UIImage imageNamed:@"multi_selected"]; + self.checkImageView.image = [UIImage wf_imageNamed:@"multi_selected"]; } else { - self.checkImageView.image = [UIImage imageNamed:@"multi_unselected"]; + self.checkImageView.image = [UIImage wf_imageNamed:@"multi_unselected"]; } } else { if (checked) { - self.checkImageView.image = [UIImage imageNamed:@"single_selected"]; + self.checkImageView.image = [UIImage wf_imageNamed:@"single_selected"]; } else { - self.checkImageView.image = [UIImage imageNamed:@"single_unselected"]; + self.checkImageView.image = [UIImage wf_imageNamed:@"single_unselected"]; } } } @@ -85,7 +85,7 @@ - (void)setMultiSelect:(BOOL)multiSelect { - (void)setFriendUid:(NSString *)friendUid { _friendUid = friendUid; WFCCUserInfo *friendInfo = [[WFCCIMService sharedWFCIMService] getUserInfo:friendUid refresh:NO]; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:friendInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:friendInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; if (friendInfo.friendAlias.length) { self.nameLabel.text = friendInfo.friendAlias; } else { diff --git a/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactTableViewCell.m b/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactTableViewCell.m index 9ab51102f..303e7dd7a 100644 --- a/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactTableViewCell.m +++ b/wfuikit/WFChatUIKit/Contacts/Cell/WFCUContactTableViewCell.m @@ -51,7 +51,7 @@ - (void)setUserId:(NSString *)userId { } - (void)updateUserInfo:(WFCCUserInfo *)userInfo { - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; if (userInfo.friendAlias.length) { self.nameLabel.text = userInfo.friendAlias; diff --git a/wfuikit/WFChatUIKit/Contacts/ViewController/WFCUContactListViewController.m b/wfuikit/WFChatUIKit/Contacts/ViewController/WFCUContactListViewController.m index d6fece5f7..f9be15ee6 100644 --- a/wfuikit/WFChatUIKit/Contacts/ViewController/WFCUContactListViewController.m +++ b/wfuikit/WFChatUIKit/Contacts/ViewController/WFCUContactListViewController.m @@ -87,7 +87,7 @@ - (void)viewDidLoad { [self updateRightBarBtn]; } } else { - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"nav_add_friend"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"nav_add_friend"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; } [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(onUserInfoUpdated:) name:kUserInfoUpdated object:nil]; @@ -315,7 +315,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N contactCell = [[WFCUNewFriendTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"newFriendCell"]; } contactCell.nameLabel.text = @"新朋友"; - contactCell.portraitView.image = [UIImage imageNamed:@"friend_request_icon"]; + contactCell.portraitView.image = [UIImage wf_imageNamed:@"friend_request_icon"]; [contactCell refresh]; return contactCell; } else if(indexPath.row == 1) { @@ -325,7 +325,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N } contactCell.nameLabel.text = @"群组"; - contactCell.portraitView.image = [UIImage imageNamed:@"contact_group_icon"]; + contactCell.portraitView.image = [UIImage wf_imageNamed:@"contact_group_icon"]; return contactCell; } else { @@ -335,7 +335,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N } contactCell.nameLabel.text = @"频道"; - contactCell.portraitView.image = [UIImage imageNamed:@"contact_channel_icon"]; + contactCell.portraitView.image = [UIImage wf_imageNamed:@"contact_channel_icon"]; return contactCell; } @@ -394,7 +394,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N } [contactCell refresh]; contactCell.nameLabel.text = @"新朋友"; - contactCell.portraitView.image = [UIImage imageNamed:@"friend_request_icon"]; + contactCell.portraitView.image = [UIImage wf_imageNamed:@"friend_request_icon"]; cell = contactCell; } else { WFCUContactTableViewCell *contactCell = [tableView dequeueReusableCellWithIdentifier:REUSEIDENTIFY]; @@ -402,7 +402,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N contactCell = [[WFCUContactTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:REUSEIDENTIFY]; } contactCell.nameLabel.text = @"群组"; - contactCell.portraitView.image = [UIImage imageNamed:@"contact_group_icon"]; + contactCell.portraitView.image = [UIImage wf_imageNamed:@"contact_group_icon"]; cell = contactCell; } } else { diff --git a/wfuikit/WFChatUIKit/ConversationList/Cell/WFCUConversationTableViewCell.m b/wfuikit/WFChatUIKit/ConversationList/Cell/WFCUConversationTableViewCell.m index 1129d2342..6184d55f9 100644 --- a/wfuikit/WFChatUIKit/ConversationList/Cell/WFCUConversationTableViewCell.m +++ b/wfuikit/WFChatUIKit/ConversationList/Cell/WFCUConversationTableViewCell.m @@ -24,7 +24,7 @@ - (void)setSelected:(BOOL)selected animated:(BOOL)animated { } - (void)updateUserInfo:(WFCCUserInfo *)userInfo { - [self.potraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.potraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; if (userInfo.friendAlias.length) { self.targetView.text = userInfo.friendAlias; @@ -36,7 +36,7 @@ - (void)updateUserInfo:(WFCCUserInfo *)userInfo { } - (void)updateChannelInfo:(WFCCChannelInfo *)channelInfo { - [self.potraitView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.potraitView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; if(channelInfo.name.length > 0) { self.targetView.text = channelInfo.name; @@ -46,7 +46,7 @@ - (void)updateChannelInfo:(WFCCChannelInfo *)channelInfo { } - (void)updateGroupInfo:(WFCCGroupInfo *)groupInfo { - [self.potraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [self.potraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; if(groupInfo.name.length > 0) { self.targetView.text = groupInfo.name; @@ -103,10 +103,10 @@ - (void)setInfo:(WFCCConversationInfo *)info { if (info.lastMessage && info.lastMessage.direction == MessageDirection_Send) { if (info.lastMessage.status == Message_Status_Sending) { - self.statusView.image = [UIImage imageNamed:@"conversation_message_sending"]; + self.statusView.image = [UIImage wf_imageNamed:@"conversation_message_sending"]; self.statusView.hidden = NO; } else if(info.lastMessage.status == Message_Status_Send_Failure) { - self.statusView.image = [UIImage imageNamed:@"MessageSendError"]; + self.statusView.image = [UIImage wf_imageNamed:@"MessageSendError"]; self.statusView.hidden = NO; } else { self.statusView.hidden = YES; @@ -210,7 +210,7 @@ - (UIImageView *)potraitView { - (UIImageView *)statusView { if (!_statusView) { _statusView = [[UIImageView alloc] initWithFrame:CGRectMake(16 + 48 + 12, 42, 16, 16)]; - _statusView.image = [UIImage imageNamed:@"conversation_message_sending"]; + _statusView.image = [UIImage wf_imageNamed:@"conversation_message_sending"]; [self.contentView addSubview:_statusView]; } return _statusView; @@ -239,7 +239,7 @@ - (UILabel *)digestView { - (UIImageView *)silentView { if (!_silentView) { _silentView = [[UIImageView alloc] initWithFrame:CGRectMake([UIScreen mainScreen].bounds.size.width - 12 - 20, 45, 12, 12)]; - _silentView.image = [UIImage imageNamed:@"conversation_mute"]; + _silentView.image = [UIImage wf_imageNamed:@"conversation_mute"]; [self.contentView addSubview:_silentView]; } return _silentView; diff --git a/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUConversationSearchTableViewCell.m b/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUConversationSearchTableViewCell.m index 4ac65a524..3a5c739eb 100644 --- a/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUConversationSearchTableViewCell.m +++ b/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUConversationSearchTableViewCell.m @@ -26,7 +26,7 @@ - (void)setSelected:(BOOL)selected animated:(BOOL)animated { - (void)updateUserInfo:(WFCCUserInfo *)userInfo { - [self.potraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.potraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; if (userInfo.friendAlias.length) { self.targetView.text = userInfo.friendAlias; diff --git a/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUSearchGroupTableViewCell.m b/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUSearchGroupTableViewCell.m index c894df180..0b8a30783 100644 --- a/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUSearchGroupTableViewCell.m +++ b/wfuikit/WFChatUIKit/ConversationList/SearchCell/WFCUSearchGroupTableViewCell.m @@ -93,7 +93,7 @@ - (void)setGroupSearchInfo:(WFCCGroupSearchInfo *)groupSearchInfo { [attrStr appendAttributedString:string]; self.haveMember.attributedText = attrStr; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; } @end diff --git a/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationSearchTableViewController.m b/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationSearchTableViewController.m index a95a23a5b..ddbcfd1d7 100644 --- a/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationSearchTableViewController.m +++ b/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationSearchTableViewController.m @@ -116,15 +116,15 @@ - (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger header.backgroundColor = [UIColor colorWithRed:239/255.f green:239/255.f blue:239/255.f alpha:1.0f]; if (self.conversation.type == Single_Type) { WFCCUserInfo *userInfo = [[WFCCIMService sharedWFCIMService] getUserInfo:self.conversation.target refresh:NO]; - [portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; label.text = [NSString stringWithFormat:@"\"%@\"的聊天记录", userInfo.displayName]; } else if (self.conversation.type == Group_Type) { WFCCGroupInfo *groupInfo = [[WFCCIMService sharedWFCIMService] getGroupInfo:self.conversation.target refresh:NO]; - [portraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"GroupChatRound"]]; + [portraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"GroupChatRound"]]; label.text = [NSString stringWithFormat:@"\"%@\"的聊天记录", groupInfo.name]; } else if(self.conversation.type == Channel_Type) { WFCCChannelInfo *channelInfo = [[WFCCIMService sharedWFCIMService] getChannelInfo:self.conversation.target refresh:NO]; - [portraitView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"GroupChatRound"]]; + [portraitView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"GroupChatRound"]]; label.text = [NSString stringWithFormat:@"\"%@\"的聊天记录", channelInfo.name]; } diff --git a/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationTableViewController.m b/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationTableViewController.m index 8a979b6b9..7da3c3989 100644 --- a/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationTableViewController.m +++ b/wfuikit/WFChatUIKit/ConversationList/ViewController/WFCUConversationTableViewController.m @@ -158,19 +158,19 @@ - (void)onRightBarBtn:(UIBarButtonItem *)sender { fromRect:CGRectMake(self.view.bounds.size.width - 56, kStatusBarAndNavigationBarHeight + searchExtra, 48, 5) menuItems:@[ [KxMenuItem menuItem:@"发起群聊" - image:[UIImage imageNamed:@"menu_start_chat"] + image:[UIImage wf_imageNamed:@"menu_start_chat"] target:self action:@selector(startChatAction:)], [KxMenuItem menuItem:@"添加朋友" - image:[UIImage imageNamed:@"menu_add_friends"] + image:[UIImage wf_imageNamed:@"menu_add_friends"] target:self action:@selector(addFriendsAction:)], [KxMenuItem menuItem:@"收听频道" - image:[UIImage imageNamed:@"menu_listen_channel"] + image:[UIImage wf_imageNamed:@"menu_listen_channel"] target:self action:@selector(listenChannelAction:)], [KxMenuItem menuItem:@"扫二维码" - image:[UIImage imageNamed:@"menu_scan_qr"] + image:[UIImage wf_imageNamed:@"menu_scan_qr"] target:self action:@selector(scanQrCodeAction:)] ]]; @@ -232,7 +232,7 @@ - (void)viewDidLoad { [self initSearchUIAndTableView]; - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"bar_plus"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"bar_plus"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(onClearAllUnread:) name:@"kTabBarClearBadgeNotification" object:nil]; @@ -418,7 +418,7 @@ - (UIView *)pcSessionView { _pcSessionView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, self.view.bounds.size.width, 40)]; [_pcSessionView setBackgroundColor:[UIColor grayColor]]; UIImageView *iv = [[UIImageView alloc] initWithFrame:CGRectMake(20, 4, 32, 32)]; - iv.image = [UIImage imageNamed:@"pc_session"]; + iv.image = [UIImage wf_imageNamed:@"pc_session"]; [_pcSessionView addSubview:iv]; UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(68, 10, 100, 20)]; label.text = @"PC已登录"; diff --git a/wfuikit/WFChatUIKit/ConversationSetting/Cell/WFCUConversationSettingMemberCell.m b/wfuikit/WFChatUIKit/ConversationSetting/Cell/WFCUConversationSettingMemberCell.m index 8972c29de..49db29a41 100644 --- a/wfuikit/WFChatUIKit/ConversationSetting/Cell/WFCUConversationSettingMemberCell.m +++ b/wfuikit/WFChatUIKit/ConversationSetting/Cell/WFCUConversationSettingMemberCell.m @@ -101,10 +101,10 @@ - (void)setModel:(NSObject *)model withType:(WFCCConversationType)type { } if (type == Channel_Type) { - [self.headerImageView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.headerImageView sd_setImageWithURL:[NSURL URLWithString:channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; self.nameLabel.text = channelInfo.name; } else { - [self.headerImageView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.headerImageView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; if (userInfo.friendAlias.length) { self.nameLabel.text = userInfo.friendAlias; diff --git a/wfuikit/WFChatUIKit/ConversationSetting/ViewController/ManagerTableViewController.m b/wfuikit/WFChatUIKit/ConversationSetting/ViewController/ManagerTableViewController.m index f125dd03a..907176b11 100644 --- a/wfuikit/WFChatUIKit/ConversationSetting/ViewController/ManagerTableViewController.m +++ b/wfuikit/WFChatUIKit/ConversationSetting/ViewController/ManagerTableViewController.m @@ -98,11 +98,11 @@ - (nonnull UITableViewCell *)tableView:(nonnull UITableView *)tableView cellForR cell.textLabel.text = owner.displayName; } else if(indexPath.section == 1) { if (indexPath.row == self.managerList.count) { - cell.imageView.image = [UIImage imageNamed:@"plus"]; + cell.imageView.image = [UIImage wf_imageNamed:@"plus"]; cell.textLabel.text = @"添加管理员"; } else { WFCCUserInfo *manager = [[WFCCIMService sharedWFCIMService] getUserInfo:[self.managerList objectAtIndex:indexPath.row].memberId refresh:NO]; - [cell.imageView sd_setImageWithURL:[NSURL URLWithString:manager.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [cell.imageView sd_setImageWithURL:[NSURL URLWithString:manager.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; cell.textLabel.text = manager.displayName; } } diff --git a/wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingViewController.m b/wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingViewController.m index d84784fb8..54e0f7cae 100644 --- a/wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingViewController.m +++ b/wfuikit/WFChatUIKit/ConversationSetting/ViewController/WFCUConversationSettingViewController.m @@ -104,7 +104,7 @@ - (void)viewDidLoad { self.channelInfo = [[WFCCIMService sharedWFCIMService] getChannelInfo:self.conversation.target refresh:YES]; self.channelPortrait = [[UIImageView alloc] initWithFrame:CGRectMake((screenWidth - portraitWidth)/2, top, portraitWidth, portraitWidth)]; - [self.channelPortrait sd_setImageWithURL:[NSURL URLWithString:self.channelInfo.portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.channelPortrait sd_setImageWithURL:[NSURL URLWithString:self.channelInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; self.channelPortrait.userInteractionEnabled = YES; [self.channelPortrait addGestureRecognizer:[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(onTapChannelPortrait:)]]; @@ -448,14 +448,14 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N } else if ([self isGroupPortraitCell:indexPath]) { UITableViewCell *cell = [self cellOfTable:tableView WithTitle:@"更改头像" withDetailTitle:nil withDisclosureIndicator:NO withSwitch:NO withSwitchType:SwitchType_Conversation_None]; UIImageView *portraitView = [[UIImageView alloc] initWithFrame:CGRectMake(self.view.frame.size.width - 56, 8, 40, 40)]; - [portraitView sd_setImageWithURL:[NSURL URLWithString:self.groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [portraitView sd_setImageWithURL:[NSURL URLWithString:self.groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; cell.accessoryView = portraitView; return cell; } else if([self isGroupQrCodeCell:indexPath]) { UITableViewCell *cell = [self cellOfTable:tableView WithTitle:@"群二维码" withDetailTitle:nil withDisclosureIndicator:YES withSwitch:NO withSwitchType:SwitchType_Conversation_None]; CGFloat width = [UIScreen mainScreen].bounds.size.width; - UIImage *qrcode = [UIImage imageNamed:@"qrcode"]; + UIImage *qrcode = [UIImage wf_imageNamed:@"qrcode"]; UIImageView *qrview = [[UIImageView alloc] initWithFrame:CGRectMake(width - 56, 5, 30, 30)]; qrview.image = qrcode; [cell addSubview:qrview]; @@ -669,11 +669,11 @@ - (__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collection [cell setModel:member withType:self.conversation.type]; } else { if (indexPath.row == self.memberList.count) { - [cell.headerImageView setImage:[UIImage imageNamed:@"addmember"]]; + [cell.headerImageView setImage:[UIImage wf_imageNamed:@"addmember"]]; cell.nameLabel.text = nil; cell.nameLabel.hidden = YES; } else { - [cell.headerImageView setImage:[UIImage imageNamed:@"removemember"]]; + [cell.headerImageView setImage:[UIImage wf_imageNamed:@"removemember"]]; cell.nameLabel.text = nil; cell.nameLabel.hidden = YES; } diff --git a/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateChannelViewController.m b/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateChannelViewController.m index d92d1d551..c51021bd3 100644 --- a/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateChannelViewController.m +++ b/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateChannelViewController.m @@ -40,7 +40,7 @@ - (void)viewDidLoad { CGFloat top = 100; self.portraitView = [[UIImageView alloc] initWithFrame:CGRectMake((bound.size.width - portraitWidth)/2, top, portraitWidth, portraitWidth)]; - self.portraitView.image = [UIImage imageNamed:@"channel_default_portrait"]; + self.portraitView.image = [UIImage wf_imageNamed:@"channel_default_portrait"]; self.portraitView.userInteractionEnabled = YES; self.portraitView.layer.borderWidth = 0.5; self.portraitView.layer.borderColor = [UIColor colorWithRed:0.1 green:0.27 blue:0.9 alpha:0.9].CGColor; diff --git a/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateGroupViewController.m b/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateGroupViewController.m index 6bf20a43f..429906083 100644 --- a/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateGroupViewController.m +++ b/wfuikit/WFChatUIKit/CreateGroup/ViewController/WFCUCreateGroupViewController.m @@ -33,7 +33,7 @@ - (void)viewDidLoad { CGRect bound = self.view.bounds; CGFloat portraitWidth = PortraitWidth; self.portraitView = [[UIImageView alloc] initWithFrame:CGRectMake((bound.size.width - portraitWidth)/2, 100, portraitWidth, portraitWidth)]; - self.portraitView.image = [UIImage imageNamed:@"group_default_portrait"]; + self.portraitView.image = [UIImage wf_imageNamed:@"group_default_portrait"]; self.portraitView.userInteractionEnabled = YES; UIGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(onSelectPortrait:)]; [self.portraitView addGestureRecognizer:tap]; @@ -89,7 +89,7 @@ - (void)viewDidLoad { } else { UIImageView *portraitView = [[UIImageView alloc] initWithFrame:self.combineHeadView.bounds]; WFCCGroupInfo *groupInfo = [[WFCCIMService sharedWFCIMService] getGroupInfo:self.groupId refresh:NO]; - [portraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [portraitView sd_setImageWithURL:[NSURL URLWithString:groupInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; [self.combineHeadView addSubview:portraitView]; } } @@ -144,7 +144,7 @@ - (void)loadCombineView { index = j + (i-1)*column + firstCol; } WFCCUserInfo *user = [users objectAtIndex:index]; - [imageView sd_setImageWithURL:[NSURL URLWithString:user.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [imageView sd_setImageWithURL:[NSURL URLWithString:user.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; [self.combineHeadView addSubview:imageView]; } } diff --git a/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardMessageCell.m b/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardMessageCell.m index 93ad3eed3..e7dbe96d6 100644 --- a/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardMessageCell.m +++ b/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardMessageCell.m @@ -41,7 +41,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"用户<%@>", conversation.target]; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; } else if (conversation.type == Group_Type) { WFCCGroupInfo *groupInfo = [[WFCCIMService sharedWFCIMService] getGroupInfo:conversation.target refresh:NO]; if (groupInfo) { @@ -50,7 +50,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"群组<%@>", conversation.target]; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; } else if (conversation.type == Channel_Type) { WFCCChannelInfo *channelInfo = [[WFCCIMService sharedWFCIMService] getChannelInfo:conversation.target refresh:NO]; if (channelInfo) { @@ -59,7 +59,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"频道<%@>", conversation.target]; } - [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.portrait sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; } diff --git a/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardViewController.m b/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardViewController.m index 8299bfad3..dc535472d 100644 --- a/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardViewController.m +++ b/wfuikit/WFChatUIKit/ForwardMessage/WFCUForwardViewController.m @@ -75,7 +75,7 @@ - (void)onLeftBarBtn:(UIBarButtonItem *)sender { } - (void)altertSend:(WFCCConversation *)conversation { - WFCUShareMessageView *shareView = [WFCUShareMessageView createViewFromNib]; + WFCUShareMessageView *shareView = [WFCUShareMessageView wf_createViewFromNib]; shareView.conversation = conversation; shareView.message = self.message; diff --git a/wfuikit/WFChatUIKit/ForwardMessage/WFCUShareMessageView.m b/wfuikit/WFChatUIKit/ForwardMessage/WFCUShareMessageView.m index 4e8165ebe..f97cfb71a 100755 --- a/wfuikit/WFChatUIKit/ForwardMessage/WFCUShareMessageView.m +++ b/wfuikit/WFChatUIKit/ForwardMessage/WFCUShareMessageView.m @@ -92,7 +92,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"用户<%@>", conversation.target]; } - [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; } else if (conversation.type == Group_Type) { WFCCGroupInfo *groupInfo = [[WFCCIMService sharedWFCIMService] getGroupInfo:conversation.target refresh:NO]; if (groupInfo) { @@ -101,7 +101,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"群组<%@>", conversation.target]; } - [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"group_default_portrait"]]; + [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"group_default_portrait"]]; } else if (conversation.type == Channel_Type) { WFCCChannelInfo *channelInfo = [[WFCCIMService sharedWFCIMService] getChannelInfo:conversation.target refresh:NO]; if (channelInfo) { @@ -110,7 +110,7 @@ - (void)setConversation:(WFCCConversation *)conversation { } else { name = [NSString stringWithFormat:@"群组<%@>", conversation.target]; } - [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage imageNamed:@"channel_default_portrait"]]; + [self.portraitImageView sd_setImageWithURL:[NSURL URLWithString:portrait] placeholderImage:[UIImage wf_imageNamed:@"channel_default_portrait"]]; } self.nameLabel.text = name; diff --git a/wfuikit/WFChatUIKit/FriendRequest/Cell/WFCUFriendRequestTableViewCell.m b/wfuikit/WFChatUIKit/FriendRequest/Cell/WFCUFriendRequestTableViewCell.m index d9a57268f..8d3801e25 100644 --- a/wfuikit/WFChatUIKit/FriendRequest/Cell/WFCUFriendRequestTableViewCell.m +++ b/wfuikit/WFChatUIKit/FriendRequest/Cell/WFCUFriendRequestTableViewCell.m @@ -71,7 +71,7 @@ - (void)onAddBtn:(id)sender { - (void)setFriendRequest:(WFCCFriendRequest *)friendRequest { _friendRequest = friendRequest; WFCCUserInfo *userInfo = [[WFCCIMService sharedWFCIMService] getUserInfo:friendRequest.target refresh:NO]; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; self.nameLabel.text = userInfo.displayName; self.reasonLabel.text = friendRequest.reason; BOOL expired = NO; diff --git a/wfuikit/WFChatUIKit/Me/WFCUMyPortraitViewController.m b/wfuikit/WFChatUIKit/Me/WFCUMyPortraitViewController.m index b78e8af9d..397e04738 100644 --- a/wfuikit/WFChatUIKit/Me/WFCUMyPortraitViewController.m +++ b/wfuikit/WFChatUIKit/Me/WFCUMyPortraitViewController.m @@ -35,7 +35,7 @@ - (void)viewDidLoad { self.userInfo = [[WFCCIMService sharedWFCIMService] getUserInfo:self.userId refresh:NO]; __weak typeof(self)ws = self; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"] completed:^(UIImage * _Nullable image, NSError * _Nullable error, SDImageCacheType cacheType, NSURL * _Nullable imageURL) { + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"] completed:^(UIImage * _Nullable image, NSError * _Nullable error, SDImageCacheType cacheType, NSURL * _Nullable imageURL) { dispatch_async(dispatch_get_main_queue(), ^{ ws.image = image; }); @@ -189,7 +189,7 @@ - (void)showHud:(NSString *)text { #pragma mark - SDPhotoBrowserDelegate - (UIImage *)photoBrowser:(SDPhotoBrowser *)browser placeholderImageForIndex:(NSInteger)index { - return [UIImage imageNamed:@"PersonalChat"]; + return [UIImage wf_imageNamed:@"PersonalChat"]; } - (NSURL *)photoBrowser:(SDPhotoBrowser *)browser highQualityImageURLForIndex:(NSInteger)index { diff --git a/wfuikit/WFChatUIKit/Me/WFCUMyProfileTableViewController.m b/wfuikit/WFChatUIKit/Me/WFCUMyProfileTableViewController.m index 9583adff4..571f7476b 100644 --- a/wfuikit/WFChatUIKit/Me/WFCUMyProfileTableViewController.m +++ b/wfuikit/WFChatUIKit/Me/WFCUMyProfileTableViewController.m @@ -79,7 +79,7 @@ - (void)loadData:(BOOL)refresh { self.portraitView.userInteractionEnabled = YES; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage: [UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:self.userInfo.portrait] placeholderImage: [UIImage wf_imageNamed:@"PersonalChat"]]; [headerCell addSubview:self.portraitView]; headerCell.tag = -1; @@ -94,7 +94,7 @@ - (void)loadData:(BOOL)refresh { cell = [self getAttrCell:@"二维码" rightText:@"" mutable:YES]; cell.tag = 1000; [self.cells1 addObject:cell]; - UIImage *qrcode = [UIImage imageNamed:@"qrcode"]; + UIImage *qrcode = [UIImage wf_imageNamed:@"qrcode"]; UIImageView *qrview = [[UIImageView alloc] initWithFrame:CGRectMake(width - 56, 5, 30, 30)]; qrview.image = qrcode; diff --git a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUCallSummaryCell.m b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUCallSummaryCell.m index 7ed98a724..2b488b30e 100644 --- a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUCallSummaryCell.m +++ b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUCallSummaryCell.m @@ -46,9 +46,9 @@ - (void)setModel:(WFCUMessageModel *)model { if ([self.model.message.content isKindOfClass:[WFCCCallStartMessageContent class]]) { WFCCCallStartMessageContent *startContent = (WFCCCallStartMessageContent *)self.model.message.content; if (startContent.isAudioOnly) { - self.modeImageView.image = [UIImage imageNamed:@"msg_audio_call"]; + self.modeImageView.image = [UIImage wf_imageNamed:@"msg_audio_call"]; } else { - self.modeImageView.image = [UIImage imageNamed:@"msg_video_call"]; + self.modeImageView.image = [UIImage wf_imageNamed:@"msg_video_call"]; } } } diff --git a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUFileCell.m b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUFileCell.m index 4b9726542..c4811b65f 100644 --- a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUFileCell.m +++ b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUFileCell.m @@ -51,7 +51,7 @@ - (void)setModel:(WFCUMessageModel *)model { self.sizeLabel.textAlignment = NSTextAlignmentRight; } - self.fileImageView.image = [UIImage imageNamed:fileImage]; + self.fileImageView.image = [UIImage wf_imageNamed:fileImage]; self.fileNameLabel.text = fileContent.name; if (fileContent.size < 1024) { self.sizeLabel.text = [NSString stringWithFormat:@"%ldB", fileContent.size]; diff --git a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUMessageCell.m b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUMessageCell.m index 00b68b0ad..ac196329e 100644 --- a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUMessageCell.m +++ b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUMessageCell.m @@ -118,7 +118,7 @@ - (void)onUserInfoUpdated:(NSNotification *)notification { - (void)updateUserInfo:(WFCCUserInfo *)userInfo { if([userInfo.userId isEqualToString:self.model.message.fromUser]) { - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:userInfo.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; if(self.model.showNameLabel) { NSString *nameStr = nil; if (userInfo.friendAlias.length) { @@ -162,7 +162,7 @@ - (void)setModel:(WFCUMessageModel *)model { } CGSize size = [self.class sizeForClientArea:model withViewWidth:[WFCUMessageCell clientAreaWidth]]; - self.bubbleView.image = [UIImage imageNamed:@"sent_msg_background"]; + self.bubbleView.image = [UIImage wf_imageNamed:@"sent_msg_background"]; self.bubbleView.frame = CGRectMake(frame.size.width - Portrait_Size - Portrait_Padding_Right -Portrait_Padding_Left - size.width - Bubble_Padding_Arraw - Bubble_Padding_Another_Side, top + Name_Client_Padding, size.width + Bubble_Padding_Arraw + Bubble_Padding_Another_Side, size.height + Client_Bubble_Top_Padding + Client_Bubble_Bottom_Padding); self.contentArea.frame = CGRectMake(Bubble_Padding_Another_Side, Client_Bubble_Top_Padding, size.width, size.height); @@ -182,7 +182,7 @@ - (void)setModel:(WFCUMessageModel *)model { } CGSize size = [self.class sizeForClientArea:model withViewWidth:[WFCUMessageCell clientAreaWidth]]; - self.bubbleView.image = [UIImage imageNamed:@"received_msg_background"]; + self.bubbleView.image = [UIImage wf_imageNamed:@"received_msg_background"]; self.bubbleView.frame = CGRectMake(Portrait_Padding_Left + Portrait_Size + Portrait_Padding_Right, top, size.width + Bubble_Padding_Arraw + Bubble_Padding_Another_Side, size.height + Client_Bubble_Top_Padding + Client_Bubble_Bottom_Padding); self.contentArea.frame = CGRectMake(Bubble_Padding_Arraw, Client_Bubble_Top_Padding, size.width, size.height); @@ -243,7 +243,7 @@ - (UIImageView *)portraitView { _portraitView = [[UIImageView alloc] init]; _portraitView.clipsToBounds = YES; _portraitView.layer.cornerRadius = 3.f; - [_portraitView setImage:[UIImage imageNamed:@"PersonalChat"]]; + [_portraitView setImage:[UIImage wf_imageNamed:@"PersonalChat"]]; [_portraitView addGestureRecognizer:[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTapPortrait:)]]; [_portraitView addGestureRecognizer:[[UILongPressGestureRecognizer alloc] initWithTarget:self action:@selector(didLongPressPortrait:)]]; @@ -304,7 +304,7 @@ - (UIActivityIndicatorView *)activityIndicatorView { - (UIImageView *)failureView { if (!_failureView) { _failureView = [[UIImageView alloc] init]; - _failureView.image = [UIImage imageNamed:@"failure"]; + _failureView.image = [UIImage wf_imageNamed:@"failure"]; [_failureView addGestureRecognizer:[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(onResend:)]]; [_failureView setUserInteractionEnabled:YES]; [self.contentView addSubview:_failureView]; diff --git a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVideoCell.m b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVideoCell.m index f44952833..a166840d5 100644 --- a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVideoCell.m +++ b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVideoCell.m @@ -34,7 +34,7 @@ - (void)setModel:(WFCUMessageModel *)model { self.thumbnailView.frame = self.bubbleView.bounds; self.thumbnailView.image = imgContent.thumbnail; self.videoCoverView.frame = CGRectMake((self.bubbleView.bounds.size.width - 80)/2, (self.bubbleView.bounds.size.height - 80)/2, 80, 80); - self.videoCoverView.image = [UIImage imageNamed:@"video_msg_cover"]; + self.videoCoverView.image = [UIImage wf_imageNamed:@"video_msg_cover"]; } - (UIImageView *)thumbnailView { diff --git a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVoiceCell.m b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVoiceCell.m index e09590a58..fffda2083 100644 --- a/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVoiceCell.m +++ b/wfuikit/WFChatUIKit/MessageList/Cell/WFCUVoiceCell.m @@ -103,7 +103,7 @@ - (void)scheduleAnimation:(id)sender { _playingImg = [NSString stringWithFormat:@"received_voice_%d", (self.animationIndex++ % 3) + 1]; } - [self.voiceBtn setImage:[UIImage imageNamed:_playingImg]]; + [self.voiceBtn setImage:[UIImage wf_imageNamed:_playingImg]]; } - (void)stopAnimationTimer { @@ -114,9 +114,9 @@ - (void)stopAnimationTimer { } if (self.model.message.direction == MessageDirection_Send) { - [self.voiceBtn setImage:[UIImage imageNamed:@"sent_voice"]]; + [self.voiceBtn setImage:[UIImage wf_imageNamed:@"sent_voice"]]; } else { - [self.voiceBtn setImage:[UIImage imageNamed:@"received_voice"]]; + [self.voiceBtn setImage:[UIImage wf_imageNamed:@"received_voice"]]; } } diff --git a/wfuikit/WFChatUIKit/MessageList/ViewController/WFCUMessageListViewController.m b/wfuikit/WFChatUIKit/MessageList/ViewController/WFCUMessageListViewController.m index 33bdc6116..b602915bc 100644 --- a/wfuikit/WFChatUIKit/MessageList/ViewController/WFCUMessageListViewController.m +++ b/wfuikit/WFChatUIKit/MessageList/ViewController/WFCUMessageListViewController.m @@ -126,7 +126,7 @@ - (void)viewDidLoad { } }]; - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"nav_chat_single"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"nav_chat_single"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; } else if(self.conversation.type == Group_Type) { [[NSNotificationCenter defaultCenter] addObserverForName:kGroupInfoUpdated object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification * _Nonnull note) { if ([ws.conversation.target isEqualToString:note.object]) { @@ -134,7 +134,7 @@ - (void)viewDidLoad { } }]; - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"nav_chat_group"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"nav_chat_group"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; } else if(self.conversation.type == Channel_Type) { [[NSNotificationCenter defaultCenter] addObserverForName:kChannelInfoUpdated object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification * _Nonnull note) { if ([ws.conversation.target isEqualToString:note.object]) { @@ -142,7 +142,7 @@ - (void)viewDidLoad { } }]; - self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"nav_chat_channel"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; + self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage wf_imageNamed:@"nav_chat_channel"] style:UIBarButtonItemStyleDone target:self action:@selector(onRightBarBtn:)]; } self.chatInputBar = [[WFCUChatInputBar alloc] initWithParentView:self.backgroundView conversation:self.conversation delegate:self]; diff --git a/wfuikit/WFChatUIKit/UIImage+Pods.m b/wfuikit/WFChatUIKit/UIImage+Pods.m deleted file mode 100644 index e7814bae2..000000000 --- a/wfuikit/WFChatUIKit/UIImage+Pods.m +++ /dev/null @@ -1,20 +0,0 @@ -// -// UIImage+Pods.m -// WFChatUIKit -// -// Created by dklinzh on 2019/7/22. -// - -#import "UIImage+Pods.h" - -@implementation UIImage (Pods) - -+ (instancetype)wf_imageNamed:(NSString *)name { -#ifdef COCOAPODS - return [self imageNamed:name inBundle:[NSBundle bundleForClass:self] compatibleWithTraitCollection:nil]; -#else - return [self imageNamed:name]; -#endif -} - -@end diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m index d089aee0a..73be49030 100755 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m @@ -149,7 +149,7 @@ - (id)init { self.backgroundColor = [UIColor colorWithRed:236.0/255.0 green:236.0/255.0 blue:236.0/255.0 alpha:1]; - NSString *resourcePath = [[NSBundle mainBundle] resourcePath]; + NSString *resourcePath = [[NSBundle wf_bundle] resourcePath]; NSString *bundlePath = [resourcePath stringByAppendingPathComponent:@"Emoj.plist"]; self.faceEmojiArray = [[NSArray alloc]initWithContentsOfFile:bundlePath]; @@ -397,8 +397,8 @@ - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cell if ((cli == FACE_COUNT_ROW -1 && col == FACE_COUNT_CLU - 1) || i == self.faceEmojiArray.count) { UIButton *back = [UIButton buttonWithType:UIButtonTypeCustom]; - [back setImage:[UIImage imageNamed:@"del_emoji_normal"] forState:UIControlStateNormal]; - [back setImage:[UIImage imageNamed:@"del_emoji_select"] forState:UIControlStateSelected]; + [back setImage:[UIImage wf_imageNamed:@"del_emoji_normal"] forState:UIControlStateNormal]; + [back setImage:[UIImage wf_imageNamed:@"del_emoji_select"] forState:UIControlStateSelected]; [back addTarget:self action:@selector(backFace) forControlEvents:UIControlEventTouchUpInside]; if (i == self.faceEmojiArray.count) { @@ -464,7 +464,7 @@ - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cell } if (indexPath.row == 0) { - iv.image = [UIImage imageNamed:@"emoji_btn_normal"]; + iv.image = [UIImage wf_imageNamed:@"emoji_btn_normal"]; } else { iv.image = [UIImage imageWithContentsOfFile:self.stickers[self.stickers.allKeys[indexPath.row - 1]].tabIcon]; } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUChatInputBar.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUChatInputBar.m index dc8dfcae6..45395b375 100644 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUChatInputBar.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUChatInputBar.m @@ -110,19 +110,19 @@ - (void)initSubViews { CGRect parentRect = self.bounds; self.voiceSwitchBtn = [[UIButton alloc] initWithFrame:CGRectMake(CHAT_INPUT_BAR_PADDING, CHAT_INPUT_BAR_PADDING, CHAT_INPUT_BAR_ICON_SIZE, CHAT_INPUT_BAR_ICON_SIZE)]; - [self.voiceSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_voice"] forState:UIControlStateNormal]; + [self.voiceSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_voice"] forState:UIControlStateNormal]; [self.voiceSwitchBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal]; [self.voiceSwitchBtn addTarget:self action:@selector(onSwitchBtn:) forControlEvents:UIControlEventTouchDown]; [self addSubview:self.voiceSwitchBtn]; self.pluginSwitchBtn = [[UIButton alloc] initWithFrame:CGRectMake(parentRect.size.width - CHAT_INPUT_BAR_HEIGHT + CHAT_INPUT_BAR_PADDING, CHAT_INPUT_BAR_PADDING, CHAT_INPUT_BAR_ICON_SIZE, CHAT_INPUT_BAR_ICON_SIZE)]; - [self.pluginSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_plugin"] forState:UIControlStateNormal]; + [self.pluginSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_plugin"] forState:UIControlStateNormal]; [self.pluginSwitchBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal]; [self.pluginSwitchBtn addTarget:self action:@selector(onSwitchBtn:) forControlEvents:UIControlEventTouchDown]; [self addSubview:self.pluginSwitchBtn]; self.emojSwitchBtn = [[UIButton alloc] initWithFrame:CGRectMake(parentRect.size.width - CHAT_INPUT_BAR_HEIGHT - CHAT_INPUT_BAR_ICON_SIZE, CHAT_INPUT_BAR_PADDING, CHAT_INPUT_BAR_ICON_SIZE, CHAT_INPUT_BAR_ICON_SIZE)]; - [self.emojSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_emoj"] forState:UIControlStateNormal]; + [self.emojSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_emoj"] forState:UIControlStateNormal]; [self.emojSwitchBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal]; [self.emojSwitchBtn addTarget:self action:@selector(onSwitchBtn:) forControlEvents:UIControlEventTouchDown]; [self addSubview:self.emojSwitchBtn]; @@ -467,11 +467,11 @@ - (void)setVoiceInput:(BOOL)voiceInput { if (self.textInputView.isFirstResponder) { [self.textInputView resignFirstResponder]; } - [self.voiceSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_keyboard"] forState:UIControlStateNormal]; + [self.voiceSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_keyboard"] forState:UIControlStateNormal]; } else { [self.textInputView setHidden:NO]; [self.voiceInputBtn setHidden:YES]; - [self.voiceSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_voice"] forState:UIControlStateNormal]; + [self.voiceSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_voice"] forState:UIControlStateNormal]; } } @@ -485,9 +485,9 @@ - (void)setEmojInput:(BOOL)emojInput { [self.textInputView becomeFirstResponder]; } [self.textInputView reloadInputViews]; - [self.emojSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_keyboard"] forState:UIControlStateNormal]; + [self.emojSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_keyboard"] forState:UIControlStateNormal]; } else { - [self.emojSwitchBtn setImage:[UIImage imageNamed:@"chat_input_bar_emoj"] forState:UIControlStateNormal]; + [self.emojSwitchBtn setImage:[UIImage wf_imageNamed:@"chat_input_bar_emoj"] forState:UIControlStateNormal]; } } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCULocationViewController.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCULocationViewController.m index 9102a142b..1ab359ffc 100644 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCULocationViewController.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCULocationViewController.m @@ -69,7 +69,7 @@ - (void)viewDidLoad { self.mapView.showsUserLocation = YES; self.annotationLayer = [CALayer layer]; - UIImage *image = [UIImage imageNamed:@"PinGreen"]; + UIImage *image = [UIImage wf_imageNamed:@"PinGreen"]; self.annotationLayer.contents = (id)image.CGImage; self.annotationLayer.frame = CGRectMake(0, 0, 35, 35); self.annotationLayer.anchorPoint = CGPointMake(0.25f, 0.f); @@ -251,7 +251,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N NSString *title = [lines componentsJoinedByString:@"\n"]; cell.textLabel.text = title; if (cell.selected) { - cell.imageView.image = [UIImage imageNamed:@"multi_selected"]; + cell.imageView.image = [UIImage wf_imageNamed:@"multi_selected"]; } else { cell.imageView.image = nil; } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUPluginBoardView.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUPluginBoardView.m index 3703d0368..5df282c8e 100644 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUPluginBoardView.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUPluginBoardView.m @@ -86,20 +86,20 @@ - (NSMutableArray *)pluginItems { if (!_pluginItems) { if (self.hasVoip) { _pluginItems = [@[ - [[PluginItem alloc] initWithTitle:@"相册" image:[UIImage imageNamed:@"chat_input_plugin_album"] tag:1], - [[PluginItem alloc] initWithTitle:@"拍摄" image:[UIImage imageNamed:@"chat_input_plugin_camera"] tag:2], - [[PluginItem alloc] initWithTitle:@"位置" image:[UIImage imageNamed:@"chat_input_plugin_location"] tag:3], + [[PluginItem alloc] initWithTitle:@"相册" image:[UIImage wf_imageNamed:@"chat_input_plugin_album"] tag:1], + [[PluginItem alloc] initWithTitle:@"拍摄" image:[UIImage wf_imageNamed:@"chat_input_plugin_camera"] tag:2], + [[PluginItem alloc] initWithTitle:@"位置" image:[UIImage wf_imageNamed:@"chat_input_plugin_location"] tag:3], #if WFCU_SUPPORT_VOIP - [[PluginItem alloc] initWithTitle:@"视频通话" image:[UIImage imageNamed:@"chat_input_plugin_video_call"] tag:4], + [[PluginItem alloc] initWithTitle:@"视频通话" image:[UIImage wf_imageNamed:@"chat_input_plugin_video_call"] tag:4], #endif - [[PluginItem alloc] initWithTitle:@"文件" image:[UIImage imageNamed:@"chat_input_plugin_file"] tag:5] + [[PluginItem alloc] initWithTitle:@"文件" image:[UIImage wf_imageNamed:@"chat_input_plugin_file"] tag:5] ] mutableCopy]; } else { _pluginItems = [@[ - [[PluginItem alloc] initWithTitle:@"相册" image:[UIImage imageNamed:@"chat_input_plugin_album"] tag:1], - [[PluginItem alloc] initWithTitle:@"拍摄" image:[UIImage imageNamed:@"chat_input_plugin_camera"] tag:2], - [[PluginItem alloc] initWithTitle:@"位置" image:[UIImage imageNamed:@"chat_input_plugin_location"] tag:3], - [[PluginItem alloc] initWithTitle:@"文件" image:[UIImage imageNamed:@"chat_input_plugin_file"] tag:5] + [[PluginItem alloc] initWithTitle:@"相册" image:[UIImage wf_imageNamed:@"chat_input_plugin_album"] tag:1], + [[PluginItem alloc] initWithTitle:@"拍摄" image:[UIImage wf_imageNamed:@"chat_input_plugin_camera"] tag:2], + [[PluginItem alloc] initWithTitle:@"位置" image:[UIImage wf_imageNamed:@"chat_input_plugin_location"] tag:3], + [[PluginItem alloc] initWithTitle:@"文件" image:[UIImage wf_imageNamed:@"chat_input_plugin_file"] tag:5] ] mutableCopy]; } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectFileViewController.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectFileViewController.m index ea8370d8f..d016cefd9 100755 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectFileViewController.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectFileViewController.m @@ -102,17 +102,17 @@ - (nonnull __kindof UICollectionViewCell *)collectionView:(nonnull UICollectionV } if (isDir) { - fileCell.backIV.image = [UIImage imageNamed:@"dir_icon"]; + fileCell.backIV.image = [UIImage wf_imageNamed:@"dir_icon"]; fileCell.selectIV.hidden = YES; } else { - fileCell.backIV.image = [UIImage imageNamed:@"file_icon"]; + fileCell.backIV.image = [UIImage wf_imageNamed:@"file_icon"]; fileCell.selectIV.hidden = NO; NSString *fullPath = [self.currentPath stringByAppendingPathComponent:self.fileArray[indexPath.row]]; if (![self.selectedFiles containsObject:fullPath]) { - fileCell.selectIV.image = [UIImage imageNamed:@"multi_unselected"]; + fileCell.selectIV.image = [UIImage wf_imageNamed:@"multi_unselected"]; }else{ - fileCell.selectIV.image = [UIImage imageNamed:@"multi_selected"]; + fileCell.selectIV.image = [UIImage wf_imageNamed:@"multi_selected"]; } } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectedFileCollectionViewCell.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectedFileCollectionViewCell.m index 501557b0e..ebe490ebd 100755 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectedFileCollectionViewCell.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUSelectedFileCollectionViewCell.m @@ -38,7 +38,7 @@ - (UIImageView *)backIV { if (!_backIV) { _backIV = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 96, 96)]; [self addSubview:_backIV]; - [_backIV setImage:[UIImage imageNamed:@"file_icon"]]; + [_backIV setImage:[UIImage wf_imageNamed:@"file_icon"]]; } return _backIV; } diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUVoiceRecordView.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUVoiceRecordView.m index e4cfbaae8..57493cbaa 100755 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUVoiceRecordView.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/WFCUVoiceRecordView.m @@ -31,7 +31,7 @@ - (id)initWithFrame:(CGRect)frame [self addSubview:bgView]; _recordAnimationView = [[UIImageView alloc] initWithFrame:CGRectMake(10, 0, self.bounds.size.width - 20, self.bounds.size.height - 30)]; - _recordAnimationView.image = [UIImage imageNamed:@"VoiceRecordFeedback001"]; + _recordAnimationView.image = [UIImage wf_imageNamed:@"VoiceRecordFeedback001"]; _recordAnimationView.contentMode = UIViewContentModeScaleAspectFit; [self addSubview:_recordAnimationView]; @@ -119,13 +119,13 @@ -(void)setCountdown:(int)countdown { } -(void)setVoiceImage:(double)voiceMeter { - _recordAnimationView.image = [UIImage imageNamed:[_voiceMessageAnimationImages objectAtIndex:0]]; + _recordAnimationView.image = [UIImage wf_imageNamed:[_voiceMessageAnimationImages objectAtIndex:0]]; double voiceSound = voiceMeter; int index = voiceSound*[_voiceMessageAnimationImages count]; if (index >= [_voiceMessageAnimationImages count]) { - _recordAnimationView.image = [UIImage imageNamed:[_voiceMessageAnimationImages lastObject]]; + _recordAnimationView.image = [UIImage wf_imageNamed:[_voiceMessageAnimationImages lastObject]]; } else { - _recordAnimationView.image = [UIImage imageNamed:[_voiceMessageAnimationImages objectAtIndex:index]]; + _recordAnimationView.image = [UIImage wf_imageNamed:[_voiceMessageAnimationImages objectAtIndex:index]]; } } diff --git a/wfuikit/WFChatUIKit/Vendor/KZSmallVideoRecorder/KZVideoSupport.m b/wfuikit/WFChatUIKit/Vendor/KZSmallVideoRecorder/KZVideoSupport.m index 5748ccaa9..0e0c428a3 100755 --- a/wfuikit/WFChatUIKit/Vendor/KZSmallVideoRecorder/KZVideoSupport.m +++ b/wfuikit/WFChatUIKit/Vendor/KZSmallVideoRecorder/KZVideoSupport.m @@ -727,7 +727,7 @@ - (instancetype)initWithFrame:(CGRect)frame { - (void)setVideoModel:(KZVideoModel *)videoModel { _videoModel = videoModel; - _thumImage.image = [UIImage imageNamed:videoModel.thumAbsolutePath]; + _thumImage.image = [UIImage wf_imageNamed:videoModel.thumAbsolutePath]; // [UIImage imageWithContentsOfFile:videoModel.totalThumPath]; } diff --git a/wfuikit/WFChatUIKit/Vendor/SDRefeshView/SDRefreshView.m b/wfuikit/WFChatUIKit/Vendor/SDRefeshView/SDRefreshView.m index 7a41fa1df..38034955f 100755 --- a/wfuikit/WFChatUIKit/Vendor/SDRefeshView/SDRefreshView.m +++ b/wfuikit/WFChatUIKit/Vendor/SDRefeshView/SDRefreshView.m @@ -47,7 +47,7 @@ - (id)initWithFrame:(CGRect)frame // 状态提示图片 UIImageView *stateIndicator = [[UIImageView alloc] init]; - stateIndicator.image = [UIImage imageNamed:@"sdRefeshView_arrow"]; + stateIndicator.image = [UIImage wf_imageNamed:@"sdRefeshView_arrow"]; [self addSubview:stateIndicator]; _stateIndicatorView = stateIndicator; _stateIndicatorView.bounds = CGRectMake(0, 0, 15, 40); diff --git a/wfuikit/WFChatUIKit/Vendor/SDWebImage/UIImageView+WebCache.h b/wfuikit/WFChatUIKit/Vendor/SDWebImage/UIImageView+WebCache.h index 568ccfd04..26185cf4f 100755 --- a/wfuikit/WFChatUIKit/Vendor/SDWebImage/UIImageView+WebCache.h +++ b/wfuikit/WFChatUIKit/Vendor/SDWebImage/UIImageView+WebCache.h @@ -37,7 +37,7 @@ // Here we use the provided sd_setImageWithURL: method to load the web image // Ensure you use a placeholder image otherwise cells will be initialized with no image [cell.imageView sd_setImageWithURL:[NSURL URLWithString:@"http://example.com/image.jpg"] - placeholderImage:[UIImage imageNamed:@"placeholder"]]; + placeholderImage:[UIImage wf_imageNamed:@"placeholder"]]; cell.textLabel.text = @"My Text"; return cell; diff --git a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/AirplayActiveView.m b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/AirplayActiveView.m index 3fc07412a..d5a5d7856 100755 --- a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/AirplayActiveView.m +++ b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/AirplayActiveView.m @@ -25,7 +25,7 @@ - (id)initWithFrame:(CGRect)frame [_gradientLayer setLocations:@[ @0.0, @1.0 ]]; [[self layer] addSublayer:_gradientLayer]; - _displayImageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"airplay-display.png"]]; + _displayImageView = [[UIImageView alloc] initWithImage:[UIImage wf_imageNamed:@"airplay-display.png"]]; [self addSubview:_displayImageView]; _titleLabel = [[UILabel alloc] initWithFrame:CGRectZero]; diff --git a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerKit.m b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerKit.m index 5e681d1e2..dfc6706d1 100755 --- a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerKit.m +++ b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerKit.m @@ -803,18 +803,18 @@ - (BOOL)isPlaying - (void)syncPlayPauseButtons { if ([self isPlaying]) { - [_videoPlayerView.playPauseButton setImage:[UIImage imageNamed:@"pause-button"] forState:UIControlStateNormal]; + [_videoPlayerView.playPauseButton setImage:[UIImage wf_imageNamed:@"pause-button"] forState:UIControlStateNormal]; } else { - [_videoPlayerView.playPauseButton setImage:[UIImage imageNamed:@"play-button"] forState:UIControlStateNormal]; + [_videoPlayerView.playPauseButton setImage:[UIImage wf_imageNamed:@"play-button"] forState:UIControlStateNormal]; } } - (void)syncFullScreenButton:(UIInterfaceOrientation)toInterfaceOrientation { if (_fullScreenModeToggled) { - [_videoPlayerView.fullScreenButton setImage:[UIImage imageNamed:@"minimize-button"] forState:UIControlStateNormal]; + [_videoPlayerView.fullScreenButton setImage:[UIImage wf_imageNamed:@"minimize-button"] forState:UIControlStateNormal]; } else { - [_videoPlayerView.fullScreenButton setImage:[UIImage imageNamed:@"fullscreen-button"] forState:UIControlStateNormal]; + [_videoPlayerView.fullScreenButton setImage:[UIImage wf_imageNamed:@"fullscreen-button"] forState:UIControlStateNormal]; } } diff --git a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerView.m b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerView.m index 2b69e3242..76875a879 100755 --- a/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerView.m +++ b/wfuikit/WFChatUIKit/Vendor/VideoPlayerKit/VideoPlayerView.m @@ -48,12 +48,12 @@ - (id)initWithFrame:(CGRect)frame [_playerControlBar setBackgroundColor:[[UIColor blackColor] colorWithAlphaComponent:0.8]]; _playPauseButton = [[UIButton alloc] init]; - [_playPauseButton setImage:[UIImage imageNamed:@"play-button"] forState:UIControlStateNormal]; + [_playPauseButton setImage:[UIImage wf_imageNamed:@"play-button"] forState:UIControlStateNormal]; [_playPauseButton setShowsTouchWhenHighlighted:YES]; [_playerControlBar addSubview:_playPauseButton]; _fullScreenButton = [[UIButton alloc] init]; - [_fullScreenButton setImage:[UIImage imageNamed:@"fullscreen-button"] forState:UIControlStateNormal]; + [_fullScreenButton setImage:[UIImage wf_imageNamed:@"fullscreen-button"] forState:UIControlStateNormal]; [_fullScreenButton setShowsTouchWhenHighlighted:YES]; [_playerControlBar addSubview:_fullScreenButton]; @@ -64,7 +64,7 @@ - (id)initWithFrame:(CGRect)frame _videoScrubber = [[UISlider alloc] init]; [_videoScrubber setMinimumTrackTintColor:[UIColor redColor]]; - [_videoScrubber setMaximumTrackImage:[UIImage imageNamed:@"transparentBar"] forState:UIControlStateNormal]; + [_videoScrubber setMaximumTrackImage:[UIImage wf_imageNamed:@"transparentBar"] forState:UIControlStateNormal]; [_videoScrubber setThumbTintColor:[UIColor whiteColor]]; [_playerControlBar addSubview:_videoScrubber]; @@ -101,7 +101,7 @@ - (id)initWithFrame:(CGRect)frame [self addSubview:_activityIndicator]; _shareButton = [[UIButton alloc] init]; - [_shareButton setImage:[UIImage imageNamed:@"share-button"] forState:UIControlStateNormal]; + [_shareButton setImage:[UIImage wf_imageNamed:@"share-button"] forState:UIControlStateNormal]; [_shareButton setShowsTouchWhenHighlighted:YES]; // Hide the Share Button by default after removing ShareThis @@ -130,7 +130,7 @@ - (void)layoutSubviews constrainedToSize:CGSizeMake(insetBounds.size.width, CGFLOAT_MAX) lineBreakMode:NSLineBreakByCharWrapping]; - UIImage *shareImage = [UIImage imageNamed:@"share-button"]; + UIImage *shareImage = [UIImage wf_imageNamed:@"share-button"]; if (!_fullscreen) { CGSize twoLineSize = [@"M\nM" sizeWithFont:[_titleLabel font] diff --git a/wfuikit/WFChatUIKit/Voip/WFCUFloatingWindow.m b/wfuikit/WFChatUIKit/Voip/WFCUFloatingWindow.m index 4346aa32f..8128873ce 100755 --- a/wfuikit/WFChatUIKit/Voip/WFCUFloatingWindow.m +++ b/wfuikit/WFChatUIKit/Voip/WFCUFloatingWindow.m @@ -211,10 +211,10 @@ - (UIButton *)floatingButton { if (!_floatingButton) { _floatingButton = [UIButton buttonWithType:UIButtonTypeCustom]; if (false /*self.callSession.mediaType == Audio*/) { - [_floatingButton setImage:[UIImage imageNamed:@"floatingaudio"] + [_floatingButton setImage:[UIImage wf_imageNamed:@"floatingaudio"] forState:UIControlStateNormal]; } else { - [_floatingButton setImage:[UIImage imageNamed:@"floatingvideo"] + [_floatingButton setImage:[UIImage wf_imageNamed:@"floatingvideo"] forState:UIControlStateNormal]; } [_floatingButton setTitle:@"" forState:UIControlStateNormal]; diff --git a/wfuikit/WFChatUIKit/Voip/WFCUVideoViewController.m b/wfuikit/WFChatUIKit/Voip/WFCUVideoViewController.m index cac6c35d1..62fe47327 100644 --- a/wfuikit/WFChatUIKit/Voip/WFCUVideoViewController.m +++ b/wfuikit/WFChatUIKit/Voip/WFCUVideoViewController.m @@ -127,7 +127,7 @@ - (void)viewDidLoad { WFCCUserInfo *user = [[WFCCIMService sharedWFCIMService] getUserInfo:self.currentSession.clientId inGroup:self.currentSession.conversation.type == Group_Type ? self.currentSession.conversation.target : nil refresh:NO]; self.portraitView = [[UIImageView alloc] init]; - [self.portraitView sd_setImageWithURL:[NSURL URLWithString:user.portrait] placeholderImage:[UIImage imageNamed:@"PersonalChat"]]; + [self.portraitView sd_setImageWithURL:[NSURL URLWithString:user.portrait] placeholderImage:[UIImage wf_imageNamed:@"PersonalChat"]]; self.portraitView.layer.masksToBounds = YES; self.portraitView.layer.cornerRadius = 8.f; [self.view addSubview:self.portraitView]; @@ -152,9 +152,9 @@ - (void)viewDidLoad { - (UIButton *)hangupButton { if (!_hangupButton) { _hangupButton = [[UIButton alloc] init]; - [_hangupButton setImage:[UIImage imageNamed:@"hangup"] forState:UIControlStateNormal]; - [_hangupButton setImage:[UIImage imageNamed:@"hangup_hover"] forState:UIControlStateHighlighted]; - [_hangupButton setImage:[UIImage imageNamed:@"hangup_hover"] forState:UIControlStateSelected]; + [_hangupButton setImage:[UIImage wf_imageNamed:@"hangup"] forState:UIControlStateNormal]; + [_hangupButton setImage:[UIImage wf_imageNamed:@"hangup_hover"] forState:UIControlStateHighlighted]; + [_hangupButton setImage:[UIImage wf_imageNamed:@"hangup_hover"] forState:UIControlStateSelected]; _hangupButton.backgroundColor = [UIColor clearColor]; [_hangupButton addTarget:self action:@selector(hanupButtonDidTap:) forControlEvents:UIControlEventTouchDown]; _hangupButton.hidden = YES; @@ -167,9 +167,9 @@ - (UIButton *)answerButton { if (!_answerButton) { _answerButton = [[UIButton alloc] init]; - [_answerButton setImage:[UIImage imageNamed:@"answer"] forState:UIControlStateNormal]; - [_answerButton setImage:[UIImage imageNamed:@"answer_hover"] forState:UIControlStateHighlighted]; - [_answerButton setImage:[UIImage imageNamed:@"answer_hover"] forState:UIControlStateSelected]; + [_answerButton setImage:[UIImage wf_imageNamed:@"answer"] forState:UIControlStateNormal]; + [_answerButton setImage:[UIImage wf_imageNamed:@"answer_hover"] forState:UIControlStateHighlighted]; + [_answerButton setImage:[UIImage wf_imageNamed:@"answer_hover"] forState:UIControlStateSelected]; _answerButton.backgroundColor = [UIColor clearColor]; [_answerButton addTarget:self action:@selector(answerButtonDidTap:) forControlEvents:UIControlEventTouchDown]; @@ -183,9 +183,9 @@ - (UIButton *)minimizeButton { if (!_minimizeButton) { _minimizeButton = [[UIButton alloc] initWithFrame:CGRectMake(16, 26, 30, 30)]; - [_minimizeButton setImage:[UIImage imageNamed:@"minimize"] forState:UIControlStateNormal]; - [_minimizeButton setImage:[UIImage imageNamed:@"minimize_hover"] forState:UIControlStateHighlighted]; - [_minimizeButton setImage:[UIImage imageNamed:@"minimize_hover"] forState:UIControlStateSelected]; + [_minimizeButton setImage:[UIImage wf_imageNamed:@"minimize"] forState:UIControlStateNormal]; + [_minimizeButton setImage:[UIImage wf_imageNamed:@"minimize_hover"] forState:UIControlStateHighlighted]; + [_minimizeButton setImage:[UIImage wf_imageNamed:@"minimize_hover"] forState:UIControlStateSelected]; _minimizeButton.backgroundColor = [UIColor clearColor]; [_minimizeButton addTarget:self action:@selector(minimizeButtonDidTap:) forControlEvents:UIControlEventTouchDown]; @@ -198,9 +198,9 @@ - (UIButton *)minimizeButton { - (UIButton *)switchCameraButton { if (!_switchCameraButton) { _switchCameraButton = [[UIButton alloc] init]; - [_switchCameraButton setImage:[UIImage imageNamed:@"switchcamera"] forState:UIControlStateNormal]; - [_switchCameraButton setImage:[UIImage imageNamed:@"switchcamera_hover"] forState:UIControlStateHighlighted]; - [_switchCameraButton setImage:[UIImage imageNamed:@"switchcamera_hover"] forState:UIControlStateSelected]; + [_switchCameraButton setImage:[UIImage wf_imageNamed:@"switchcamera"] forState:UIControlStateNormal]; + [_switchCameraButton setImage:[UIImage wf_imageNamed:@"switchcamera_hover"] forState:UIControlStateHighlighted]; + [_switchCameraButton setImage:[UIImage wf_imageNamed:@"switchcamera_hover"] forState:UIControlStateSelected]; _switchCameraButton.backgroundColor = [UIColor clearColor]; [_switchCameraButton addTarget:self action:@selector(switchCameraButtonDidTap:) forControlEvents:UIControlEventTouchDown]; _switchCameraButton.hidden = YES; @@ -212,9 +212,9 @@ - (UIButton *)switchCameraButton { - (UIButton *)downgradeButton { if (!_downgradeButton) { _downgradeButton = [[UIButton alloc] init]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio"] forState:UIControlStateNormal]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio_hover"] forState:UIControlStateHighlighted]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio_hover"] forState:UIControlStateSelected]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio"] forState:UIControlStateNormal]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio_hover"] forState:UIControlStateHighlighted]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio_hover"] forState:UIControlStateSelected]; _downgradeButton.backgroundColor = [UIColor clearColor]; [_downgradeButton addTarget:self action:@selector(downgradeButtonDidTap:) forControlEvents:UIControlEventTouchDown]; _downgradeButton.hidden = YES; @@ -226,9 +226,9 @@ - (UIButton *)downgradeButton { - (UIButton *)audioButton { if (!_audioButton) { _audioButton = [[UIButton alloc] initWithFrame:CGRectMake(self.view.frame.size.width/2-ButtonSize/2, self.view.frame.size.height-10-ButtonSize, ButtonSize, ButtonSize)]; - [_audioButton setImage:[UIImage imageNamed:@"mute"] forState:UIControlStateNormal]; - [_audioButton setImage:[UIImage imageNamed:@"mute_hover"] forState:UIControlStateHighlighted]; - [_audioButton setImage:[UIImage imageNamed:@"mute_hover"] forState:UIControlStateSelected]; + [_audioButton setImage:[UIImage wf_imageNamed:@"mute"] forState:UIControlStateNormal]; + [_audioButton setImage:[UIImage wf_imageNamed:@"mute_hover"] forState:UIControlStateHighlighted]; + [_audioButton setImage:[UIImage wf_imageNamed:@"mute_hover"] forState:UIControlStateSelected]; _audioButton.backgroundColor = [UIColor clearColor]; [_audioButton addTarget:self action:@selector(audioButtonDidTap:) forControlEvents:UIControlEventTouchDown]; _audioButton.hidden = YES; @@ -239,9 +239,9 @@ - (UIButton *)audioButton { - (UIButton *)speakerButton { if (!_speakerButton) { _speakerButton = [[UIButton alloc] initWithFrame:CGRectMake(self.view.frame.size.width/2-ButtonSize/2, self.view.frame.size.height-10-ButtonSize, ButtonSize, ButtonSize)]; - [_speakerButton setImage:[UIImage imageNamed:@"speaker"] forState:UIControlStateNormal]; - [_speakerButton setImage:[UIImage imageNamed:@"speaker_hover"] forState:UIControlStateHighlighted]; - [_speakerButton setImage:[UIImage imageNamed:@"speaker_hover"] forState:UIControlStateSelected]; + [_speakerButton setImage:[UIImage wf_imageNamed:@"speaker"] forState:UIControlStateNormal]; + [_speakerButton setImage:[UIImage wf_imageNamed:@"speaker_hover"] forState:UIControlStateHighlighted]; + [_speakerButton setImage:[UIImage wf_imageNamed:@"speaker_hover"] forState:UIControlStateSelected]; _speakerButton.backgroundColor = [UIColor clearColor]; [_speakerButton addTarget:self action:@selector(speakerButtonDidTap:) forControlEvents:UIControlEventTouchDown]; _speakerButton.hidden = YES; @@ -341,9 +341,9 @@ - (void)audioButtonDidTap:(UIButton *)button { if (result) { self.audioMuted = !self.audioMuted; if (self.audioMuted) { - [self.audioButton setImage:[UIImage imageNamed:@"mute_hover"] forState:UIControlStateNormal]; + [self.audioButton setImage:[UIImage wf_imageNamed:@"mute_hover"] forState:UIControlStateNormal]; } else { - [self.audioButton setImage:[UIImage imageNamed:@"mute"] forState:UIControlStateNormal]; + [self.audioButton setImage:[UIImage wf_imageNamed:@"mute"] forState:UIControlStateNormal]; } } @@ -359,9 +359,9 @@ - (void)speakerButtonDidTap:(UIButton *)button { - (void)updateSpeakerButton { if (!self.currentSession.isSpeaker) { - [self.speakerButton setImage:[UIImage imageNamed:@"speaker"] forState:UIControlStateNormal]; + [self.speakerButton setImage:[UIImage wf_imageNamed:@"speaker"] forState:UIControlStateNormal]; } else { - [self.speakerButton setImage:[UIImage imageNamed:@"speaker_hover"] forState:UIControlStateNormal]; + [self.speakerButton setImage:[UIImage wf_imageNamed:@"speaker_hover"] forState:UIControlStateNormal]; } } @@ -582,18 +582,18 @@ - (void)didChangeState:(WFAVEngineState)state { self.smallVideoView.hidden = YES; self.bigVideoView.hidden = YES; - [_downgradeButton setImage:[UIImage imageNamed:@"to_video"] forState:UIControlStateNormal]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_video_hover"] forState:UIControlStateHighlighted]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_video_hover"] forState:UIControlStateSelected]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_video"] forState:UIControlStateNormal]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_video_hover"] forState:UIControlStateHighlighted]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_video_hover"] forState:UIControlStateSelected]; } else { [self.currentSession setupLocalVideoView:self.smallVideoView scalingType:self.scalingType]; [self.currentSession setupRemoteVideoView:self.bigVideoView scalingType:self.scalingType]; self.smallVideoView.hidden = NO; self.bigVideoView.hidden = NO; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio"] forState:UIControlStateNormal]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio_hover"] forState:UIControlStateHighlighted]; - [_downgradeButton setImage:[UIImage imageNamed:@"to_audio_hover"] forState:UIControlStateSelected]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio"] forState:UIControlStateNormal]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio_hover"] forState:UIControlStateHighlighted]; + [_downgradeButton setImage:[UIImage wf_imageNamed:@"to_audio_hover"] forState:UIControlStateSelected]; } From bddf7067ccd822207c81454b69f5968c7f65488e Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Tue, 23 Jul 2019 17:25:27 +0800 Subject: [PATCH 06/10] build(pods): configure public/private headers of vendor framework in `subspec` --- wfchat/Podfile.lock | 2 +- wfuikit/WFChatUIKit.podspec | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock index 69358b5b3..f0c37fc13 100644 --- a/wfchat/Podfile.lock +++ b/wfchat/Podfile.lock @@ -124,7 +124,7 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: WFChatClient: 7b869b8c794d5b23f75144e577c09e6a99fb6530 - WFChatUIKit: cd315dbcce34a5ac2541e81eb55c77a1b2508c9a + WFChatUIKit: d98218a1d718b07a619d2555c44af3ec2bdff452 PODFILE CHECKSUM: 2f1c7b0c5e5bb85465ace5c46b6316b9c5b1b2dd diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index 653f77acb..17b7ed0db 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -97,59 +97,73 @@ Pod::Spec.new do |s| s.subspec 'Vendor' do |ss| ss.subspec 'ChatInputBar' do |sss| + sss.public_header_files = 'WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.h' sss.source_files = 'WFChatUIKit/Vendor/ChatInputBar/**/*.{h,m}' sss.resources = 'WFChatUIKit/Resources/Stickers.bundle', 'WFChatUIKit/Resources/Emoj.plist' end ss.subspec 'CCHMapClusterController' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.{h,m}' end ss.subspec 'Pinyin' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/Pinyin/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/Pinyin/**/*.{h,c}' end ss.subspec 'VideoPlayerKit' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.{h,m}' end ss.subspec 'KZSmallVideoRecorder' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.{h,m}' end ss.subspec 'SDPhotoBrowser' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.{h,m}' end ss.subspec 'KxMenu' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/KxMenu/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/KxMenu/**/*.{h,m}' end ss.subspec 'AFNetworking' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.{h,m}' end ss.subspec 'MBProgressHUD' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.{h,m}' end ss.subspec 'SDRefeshView' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.{h,m}' end ss.subspec 'UITextViewPlaceholder' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.{h,m}' end ss.subspec 'SDWebImage' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.{h,m}' end ss.subspec 'TYAlertController' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.{h,m}' end ss.subspec 'YLGIFImage' do |sss| + sss.private_header_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.{h,m}' end From e5c8daa49fd4964be38a1cdf5df7cb81049090a5 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Sat, 27 Jul 2019 21:44:35 +0800 Subject: [PATCH 07/10] build(git): update `.gitignore` --- .gitignore | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 8f698a0a2..51d446e17 100644 --- a/.gitignore +++ b/.gitignore @@ -52,11 +52,7 @@ Index/ !default.perspectivev3 xcuserdata/ -## Xcode Patch -*.xcodeproj/* -!*.xcodeproj/project.pbxproj -!*.xcodeproj/xcshareddata/ -!*.xcworkspace/contents.xcworkspacedata +## Gcc Patch /*.gcno ## Other From 9e22ef37b9dc8958a8dfca962c6635a0bcd6d904 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Tue, 30 Jul 2019 17:26:27 +0800 Subject: [PATCH 08/10] build: disable bitcode for the unsupported vendored frameworks --- wfclient/WFChatClient.podspec | 3 +++ wfuikit/WFChatUIKit.podspec | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/wfclient/WFChatClient.podspec b/wfclient/WFChatClient.podspec index b43712ed4..11469a02f 100644 --- a/wfclient/WFChatClient.podspec +++ b/wfclient/WFChatClient.podspec @@ -20,6 +20,9 @@ Pod::Spec.new do |s| s.subspec 'Proto' do |ss| ss.vendored_frameworks = 'WFChatClient/Proto/**/*.framework' + ss.pod_target_xcconfig = { + 'ENABLE_BITCODE' => 'NO' + } end s.subspec 'Messages' do |ss| diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index 17b7ed0db..dde79deb4 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -24,7 +24,10 @@ Pod::Spec.new do |s| s.subspec 'AVEngine' do |ss| ss.vendored_frameworks = 'WFChatUIKit/AVEngine/**/*.framework' ss.pod_target_xcconfig = { - 'OTHER_LDFLAGS' => '$(inherited) -ObjC -framework WFAVEngineKit -framework WebRTC' + 'OTHER_LDFLAGS' => '$(inherited) -framework WFAVEngineKit -framework WebRTC' + } + ss.xcconfig = { + 'ENABLE_BITCODE' => 'NO' } end From 0359c7acf7cbaa0c7448bc3170927901f2f6e4df Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Mon, 5 Aug 2019 10:21:56 +0800 Subject: [PATCH 09/10] fix(pods): make headers of vendor framework public and remove the unnecessary references of framework headers in project --- wfchat/Podfile.lock | 4 +- wfchat/WildFireChat.xcodeproj/project.pbxproj | 109 ------------------ wfuikit/WFChatUIKit.podspec | 28 ++--- 3 files changed, 16 insertions(+), 125 deletions(-) diff --git a/wfchat/Podfile.lock b/wfchat/Podfile.lock index f0c37fc13..83a04b366 100644 --- a/wfchat/Podfile.lock +++ b/wfchat/Podfile.lock @@ -123,8 +123,8 @@ EXTERNAL SOURCES: :path: "../wfuikit" SPEC CHECKSUMS: - WFChatClient: 7b869b8c794d5b23f75144e577c09e6a99fb6530 - WFChatUIKit: d98218a1d718b07a619d2555c44af3ec2bdff452 + WFChatClient: 254212ba49952db92c9485965ce5ba13857293e6 + WFChatUIKit: eb68d0298ee120e0ab3ef281dd5814d49b4f7f68 PODFILE CHECKSUM: 2f1c7b0c5e5bb85465ace5c46b6316b9c5b1b2dd diff --git a/wfchat/WildFireChat.xcodeproj/project.pbxproj b/wfchat/WildFireChat.xcodeproj/project.pbxproj index a5ea539ba..c64a93498 100644 --- a/wfchat/WildFireChat.xcodeproj/project.pbxproj +++ b/wfchat/WildFireChat.xcodeproj/project.pbxproj @@ -96,38 +96,6 @@ 2E1D20BD1FAF127100F4405D /* DiscoverViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DiscoverViewController.h; sourceTree = ""; }; 2E1D20BE1FAF127100F4405D /* DiscoverViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DiscoverViewController.m; sourceTree = ""; }; 2EF30A58201995630060992B /* WildFireChat.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = WildFireChat.entitlements; sourceTree = ""; }; - 2F143A02217F5F3700B3E38A /* NSImage+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSImage+WebCache.h"; sourceTree = ""; }; - 2F143A03217F5F3700B3E38A /* UIImageView+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+WebCache.h"; sourceTree = ""; }; - 2F143A04217F5F3700B3E38A /* NSData+ImageContentType.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSData+ImageContentType.h"; sourceTree = ""; }; - 2F143A07217F5F3700B3E38A /* SDWebImageDownloaderOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageDownloaderOperation.h; sourceTree = ""; }; - 2F143A09217F5F3700B3E38A /* SDImageCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDImageCache.h; sourceTree = ""; }; - 2F143A0A217F5F3700B3E38A /* SDImageCacheConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDImageCacheConfig.h; sourceTree = ""; }; - 2F143A10217F5F3700B3E38A /* FLAnimatedImage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FLAnimatedImage.h; sourceTree = ""; }; - 2F143A11217F5F3700B3E38A /* FLAnimatedImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FLAnimatedImageView.h; sourceTree = ""; }; - 2F143A12217F5F3700B3E38A /* FLAnimatedImageView+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "FLAnimatedImageView+WebCache.h"; sourceTree = ""; }; - 2F143A15217F5F3700B3E38A /* UIButton+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIButton+WebCache.h"; sourceTree = ""; }; - 2F143A19217F5F3700B3E38A /* SDWebImage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImage.h; sourceTree = ""; }; - 2F143A1A217F5F3700B3E38A /* UIView+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+WebCache.h"; sourceTree = ""; }; - 2F143A1B217F5F3700B3E38A /* UIView+WebCacheOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+WebCacheOperation.h"; sourceTree = ""; }; - 2F143A1C217F5F3700B3E38A /* MKAnnotationView+WebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MKAnnotationView+WebCache.h"; sourceTree = ""; }; - 2F143A1D217F5F3700B3E38A /* UIImage+WebP.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImage+WebP.h"; sourceTree = ""; }; - 2F143A1F217F5F3700B3E38A /* UIImageView+HighlightedWebCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+HighlightedWebCache.h"; sourceTree = ""; }; - 2F143A21217F5F3700B3E38A /* SDWebImageDecoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageDecoder.h; sourceTree = ""; }; - 2F143A22217F5F3700B3E38A /* SDWebImageManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageManager.h; sourceTree = ""; }; - 2F143A25217F5F3700B3E38A /* SDWebImageOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageOperation.h; sourceTree = ""; }; - 2F143A27217F5F3700B3E38A /* SDWebImageDownloader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageDownloader.h; sourceTree = ""; }; - 2F143A2B217F5F3700B3E38A /* SDWebImagePrefetcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImagePrefetcher.h; sourceTree = ""; }; - 2F143A2C217F5F3700B3E38A /* SDWebImageCompat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDWebImageCompat.h; sourceTree = ""; }; - 2F143A2D217F5F3700B3E38A /* UIImage+MultiFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImage+MultiFormat.h"; sourceTree = ""; }; - 2F143A2F217F5F3700B3E38A /* UIImage+GIF.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImage+GIF.h"; sourceTree = ""; }; - 2F143A47217F607300B3E38A /* AFSecurityPolicy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFSecurityPolicy.h; sourceTree = ""; }; - 2F143A48217F607300B3E38A /* AFNetworkReachabilityManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworkReachabilityManager.h; sourceTree = ""; }; - 2F143A49217F607300B3E38A /* AFURLSessionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFURLSessionManager.h; sourceTree = ""; }; - 2F143A4A217F607300B3E38A /* AFURLRequestSerialization.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFURLRequestSerialization.h; sourceTree = ""; }; - 2F143A4D217F607300B3E38A /* AFURLResponseSerialization.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFURLResponseSerialization.h; sourceTree = ""; }; - 2F143A50217F607300B3E38A /* AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworking.h; sourceTree = ""; }; - 2F143A53217F607300B3E38A /* AFHTTPSessionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPSessionManager.h; sourceTree = ""; }; - 2F143A5C217F60B600B3E38A /* MBProgressHUD.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MBProgressHUD.h; sourceTree = ""; }; 2F1B0DCC21E19AF400139CB1 /* UserNotificationsUI.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UserNotificationsUI.framework; path = System/Library/Frameworks/UserNotificationsUI.framework; sourceTree = SDKROOT; }; 2F1B0DCD21E19AF400139CB1 /* NotificationCenter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = NotificationCenter.framework; path = System/Library/Frameworks/NotificationCenter.framework; sourceTree = SDKROOT; }; 2F1B0DCE21E19AF400139CB1 /* UserNotifications.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UserNotifications.framework; path = System/Library/Frameworks/UserNotifications.framework; sourceTree = SDKROOT; }; @@ -261,10 +229,7 @@ 2F7268FA21F7137C00E05F9C /* YBAttributeTextTapAction */, 2F7268F621F7136600E05F9C /* Privacy */, 2FEA5D6721F4AC8900280B23 /* Login */, - 2F143A5A217F60B600B3E38A /* MBProgressHUD */, - 2F143A46217F607300B3E38A /* AFNetworking */, 2E1D20BC1FAF127100F4405D /* Discover */, - 2F1439FF217F5F3700B3E38A /* SDWebImage */, 2E1D1FFA1FAF0AE600F4405D /* AppDelegate.h */, 2E1D1FFB1FAF0AE600F4405D /* AppDelegate.m */, 2E1D20AE1FAF125D00F4405D /* WFCBaseTabBarController.h */, @@ -306,78 +271,6 @@ path = Frameworks; sourceTree = ""; }; - 2F1439FF217F5F3700B3E38A /* SDWebImage */ = { - isa = PBXGroup; - children = ( - 2F143A02217F5F3700B3E38A /* NSImage+WebCache.h */, - 2F143A03217F5F3700B3E38A /* UIImageView+WebCache.h */, - 2F143A04217F5F3700B3E38A /* NSData+ImageContentType.h */, - 2F143A07217F5F3700B3E38A /* SDWebImageDownloaderOperation.h */, - 2F143A09217F5F3700B3E38A /* SDImageCache.h */, - 2F143A0A217F5F3700B3E38A /* SDImageCacheConfig.h */, - 2F143A0B217F5F3700B3E38A /* FLAnimatedImage */, - 2F143A15217F5F3700B3E38A /* UIButton+WebCache.h */, - 2F143A19217F5F3700B3E38A /* SDWebImage.h */, - 2F143A1A217F5F3700B3E38A /* UIView+WebCache.h */, - 2F143A1B217F5F3700B3E38A /* UIView+WebCacheOperation.h */, - 2F143A1C217F5F3700B3E38A /* MKAnnotationView+WebCache.h */, - 2F143A1D217F5F3700B3E38A /* UIImage+WebP.h */, - 2F143A1F217F5F3700B3E38A /* UIImageView+HighlightedWebCache.h */, - 2F143A21217F5F3700B3E38A /* SDWebImageDecoder.h */, - 2F143A22217F5F3700B3E38A /* SDWebImageManager.h */, - 2F143A25217F5F3700B3E38A /* SDWebImageOperation.h */, - 2F143A27217F5F3700B3E38A /* SDWebImageDownloader.h */, - 2F143A2B217F5F3700B3E38A /* SDWebImagePrefetcher.h */, - 2F143A2C217F5F3700B3E38A /* SDWebImageCompat.h */, - 2F143A2D217F5F3700B3E38A /* UIImage+MultiFormat.h */, - 2F143A2F217F5F3700B3E38A /* UIImage+GIF.h */, - ); - name = SDWebImage; - path = ../../wfuikit/WFChatUIKit/Vendor/SDWebImage; - sourceTree = ""; - }; - 2F143A0B217F5F3700B3E38A /* FLAnimatedImage */ = { - isa = PBXGroup; - children = ( - 2F143A0D217F5F3700B3E38A /* FLAnimatedImage */, - 2F143A12217F5F3700B3E38A /* FLAnimatedImageView+WebCache.h */, - ); - path = FLAnimatedImage; - sourceTree = ""; - }; - 2F143A0D217F5F3700B3E38A /* FLAnimatedImage */ = { - isa = PBXGroup; - children = ( - 2F143A10217F5F3700B3E38A /* FLAnimatedImage.h */, - 2F143A11217F5F3700B3E38A /* FLAnimatedImageView.h */, - ); - path = FLAnimatedImage; - sourceTree = ""; - }; - 2F143A46217F607300B3E38A /* AFNetworking */ = { - isa = PBXGroup; - children = ( - 2F143A47217F607300B3E38A /* AFSecurityPolicy.h */, - 2F143A48217F607300B3E38A /* AFNetworkReachabilityManager.h */, - 2F143A49217F607300B3E38A /* AFURLSessionManager.h */, - 2F143A4A217F607300B3E38A /* AFURLRequestSerialization.h */, - 2F143A4D217F607300B3E38A /* AFURLResponseSerialization.h */, - 2F143A50217F607300B3E38A /* AFNetworking.h */, - 2F143A53217F607300B3E38A /* AFHTTPSessionManager.h */, - ); - name = AFNetworking; - path = ../../wfuikit/WFChatUIKit/Vendor/AFNetworking; - sourceTree = ""; - }; - 2F143A5A217F60B600B3E38A /* MBProgressHUD */ = { - isa = PBXGroup; - children = ( - 2F143A5C217F60B600B3E38A /* MBProgressHUD.h */, - ); - name = MBProgressHUD; - path = ../../wfuikit/WFChatUIKit/Vendor/MBProgressHUD; - sourceTree = ""; - }; 2F7268F621F7136600E05F9C /* Privacy */ = { isa = PBXGroup; children = ( @@ -883,7 +776,6 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_TEAM = ""; - ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/WildFireChat/framework", @@ -916,7 +808,6 @@ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_TEAM = ""; - ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/WildFireChat/framework", diff --git a/wfuikit/WFChatUIKit.podspec b/wfuikit/WFChatUIKit.podspec index dde79deb4..957f85ff2 100644 --- a/wfuikit/WFChatUIKit.podspec +++ b/wfuikit/WFChatUIKit.podspec @@ -100,73 +100,73 @@ Pod::Spec.new do |s| s.subspec 'Vendor' do |ss| ss.subspec 'ChatInputBar' do |sss| - sss.public_header_files = 'WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.h' +# sss.public_header_files = 'WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.h' sss.source_files = 'WFChatUIKit/Vendor/ChatInputBar/**/*.{h,m}' sss.resources = 'WFChatUIKit/Resources/Stickers.bundle', 'WFChatUIKit/Resources/Emoj.plist' end ss.subspec 'CCHMapClusterController' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/CCHMapClusterController/**/*.{h,m}' end ss.subspec 'Pinyin' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/Pinyin/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/Pinyin/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/Pinyin/**/*.{h,c}' end ss.subspec 'VideoPlayerKit' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/VideoPlayerKit/**/*.{h,m}' end ss.subspec 'KZSmallVideoRecorder' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/KZSmallVideoRecorder/**/*.{h,m}' end ss.subspec 'SDPhotoBrowser' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDPhotoBrowser/**/*.{h,m}' end ss.subspec 'KxMenu' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/KxMenu/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/KxMenu/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/KxMenu/**/*.{h,m}' end ss.subspec 'AFNetworking' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/AFNetworking/**/*.{h,m}' end ss.subspec 'MBProgressHUD' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/MBProgressHUD/**/*.{h,m}' end ss.subspec 'SDRefeshView' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDRefeshView/**/*.{h,m}' end ss.subspec 'UITextViewPlaceholder' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/UITextViewPlaceholder/**/*.{h,m}' end ss.subspec 'SDWebImage' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/SDWebImage/**/*.{h,m}' end ss.subspec 'TYAlertController' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/TYAlertController/**/*.{h,m}' end ss.subspec 'YLGIFImage' do |sss| - sss.private_header_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.h' +# sss.private_header_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.h' sss.source_files = 'WFChatUIKit/Vendor/YLGIFImage/**/*.{h,m}' end From c02a8cdb9cd45da9e82ba89843d157dfde0d2d24 Mon Sep 17 00:00:00 2001 From: Daniel Lin Date: Mon, 5 Aug 2019 10:23:25 +0800 Subject: [PATCH 10/10] fix: fix bug of loading resources from the bundle in framework --- .../WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m index 73be49030..4a280d890 100755 --- a/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m +++ b/wfuikit/WFChatUIKit/Vendor/ChatInputBar/FaceBoard/WFCUFaceBoard.m @@ -94,7 +94,8 @@ + (void)initStickers { - (void)loadStickers { self.stickers = [[NSMutableDictionary alloc] init]; - NSString *stickerPath = [[WFCUFaceBoard getStickerCachePath] stringByAppendingPathComponent:[WFCUFaceBoard getStickerBundleName]]; +// NSString *stickerPath = [[WFCUFaceBoard getStickerCachePath] stringByAppendingPathComponent:[WFCUFaceBoard getStickerBundleName]]; + NSString *stickerPath = [[NSBundle bundleForClass:self.class].resourcePath stringByAppendingPathComponent:[WFCUFaceBoard getStickerBundleName]]; NSError * err = nil; NSFileManager * defaultManager = [NSFileManager defaultManager];