// // PrefixHeader.pch // Starbuds // // Created by 翟玉磊 on 2019/12/4. // Copyright © 2019 翟玉磊. All rights reserved. // #ifndef PrefixHeader_pch #define PrefixHeader_pch /// 系统框架 #import #import #import "AppConstEnumHeader.h" /// 枚举、结构体 /// 数据操作 #import "CoreDataManager.h" #import "DataBase.h" #import "User+CoreDataClass.h" #import "Notification+CoreDataClass.h" #import "Music+CoreDataClass.h" #import "Medal+CoreDataClass.h" /// 常用的类 #import "XYAppConfigModel.h" //app配置信息 #import "AppDelegate.h" #import "AppDelegate+XYShanYan.h" #import "AppDelegate+XYPush.h" //推送相关 #import "XYUserModel.h" //用户model #import "XYChannelInfoManager.h"// 渠道信息 #import "XYIMBaseManager.h" //im封装基础类 #import "MessageManagerHeader.h"// 消息管理类 #import "CommonClassHeader.h" // 常用的自定义类 #import "XYLiveManger.h" #import "XYRichText.h" #import "NSString+KCExtend.h" #import "UILabel+ChangeDefaultFont.h" #import "UIButton+SSEdgeInsets.h" #import "XYImageTextSelectCommonInfo.h" #import "StatisticsManager.h" #pragma mark - 第三方库 /// YYKit #import "YYCategories.h" //#import "YYText.h" #import "YYModel.h" //#import "YYWebImage.h" //#import "YYImage.h" //#import "YYCache.h" #import //屏幕适配 #import //缓存tableViewCell的高度 #import //侧滑手势 //#import // 字典转模型 该项目使用YYModel #import /// 上下拉刷新控件 #import // 颜色分类 #import //根据颜色 生成一张图片 #import //提示view #import //提示view //#import /// sqlist数据库 /// 消息链 #import #import /// 网络请求 #import "UIImageView+WebCache.h" /// 图片请求缓存管理 #import //模糊效果 //#import ///富文本操作 #import /// UICollectionView左对齐布局 #import // json动画处理库 (AE动画) #import /// 键盘管理 #import /// 瀑布流 #import "TZImagePickerController.h" /// 图片浏览器 #import #import "SDCycleScrollView.h" /// 轮播图 /// header #import "AppConfigHeader.h" /// APP配置 #import "SizeMacroHeader.h" /// APP尺寸 #import "AppFontHeader.h" /// 文字 #import "AppColorHeader.h" /// 颜色 #import "BaseHeader.h" /// 基础类 #import "VoiceRoomHeader.h" /// 语音房相关配置 #pragma mark - 常用宏 #define ApplicationDelegate ((AppDelegate *)[UIApplication sharedApplication].delegate) /// IOS系统版本 #define IOS_Version [[[UIDevice currentDevice] systemVersion] floatValue] /// 判断系统版本是否大于等于x #define IS_IOS_(x) ((IOS_Version >= x) ? YES : NO) /// 防止block循环引用 #define WeakSelf __weak __typeof(self)weakSelf = self; /// 销毁打印 #define ClassDealloc NSLog(@"\n =========+++ %@ 销毁了 +++======== \n",[self class]) // 是否为空对象 #define ObjectIsNil(__object) ((nil == __object) || [__object isKindOfClass:[NSNull class]]) /// 字符串为空 #define StringIsEmpty(__string) ((__string.length == 0) || ObjectIsNil(__string)) // 字符串不为空 #define StringIsNotEmpty(__string) (!StringIsEmpty(__string)) // 数组为空 #define ArrayIsEmpty(__array) ((ObjectIsNil(__array)) || (__array.count==0)) /// AppCaches 文件夹路径 #define CachesDirectory [NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES) lastObject] /// App DocumentDirectory 文件夹路径 #define DocumentDirectory [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES) lastObject] /// 设置图片 #define ImageNamed(__imageName) [UIImage imageNamed:__imageName] /// 字符串转URL #define UrlForString(__urlString) [NSURL URLWithString:__urlString] /// 通知中心 #define NotificationCenter [NSNotificationCenter defaultCenter] /// 本地保存NSUserDefaults #define UserDefaults [NSUserDefaults standardUserDefaults] #define kLocalizedString(string) [NSString kcLocalizedString:string] #define kXYLanguageSet @"XYLanguageSet" #pragma mark - Log宏 /// 输出日志 (格式: [时间] [哪个方法] [哪行] [输出内容]) #ifdef DEBUG #define NSLog(format, ...) printf("\n[%s] %s [第%d行] 💕 %s\n", __TIME__, __FUNCTION__, __LINE__, [[NSString stringWithFormat:format, ##__VA_ARGS__] UTF8String]); #else #define NSLog(format, ...) #endif /// 打印方法 #define LogFunc NSLog(@"%s", __func__) /// 适配iPhone X + iOS 11 #define AdjustsScrollViewInsets_Never(__scrollView)\ do {\ _Pragma("clang diagnostic push")\ _Pragma("clang diagnostic ignored \"-Warc-performSelector-leaks\"")\ if ([__scrollView respondsToSelector:NSSelectorFromString(@"setContentInsetAdjustmentBehavior:")]) {\ NSMethodSignature *signature = [UIScrollView instanceMethodSignatureForSelector:@selector(setContentInsetAdjustmentBehavior:)];\ NSInvocation *invocation = [NSInvocation invocationWithMethodSignature:signature];\ NSInteger argument = 2;\ invocation.target = __scrollView;\ invocation.selector = @selector(setContentInsetAdjustmentBehavior:);\ [invocation setArgument:&argument atIndex:2];\ [invocation retainArguments];\ [invocation invoke];\ }\ _Pragma("clang diagnostic pop")\ } while (0) #endif /* PrefixHeader_pch */