// // PrefixHeader.pch // OneSentence // // Created by ko1o on 2019/3/2. // Copyright © 2019年 ko1o. All rights reserved. // #ifndef PrefixHeader_pch #define PrefixHeader_pch #define IS_DEBUG (DEBUG && 0) #if IS_DEBUG #define TIM_APPID 1400722507 #define TIM_PUSHID 36078 #else #define TIM_APPID 1400722507 #define TIM_PUSHID 36078 #endif //pro 36078 dev 36077 //#if IS_DEBUG //#define GETUI_APPID @"poCj93sZUa8gmaiuBm9hO3" //#define GETUI_APPKEY @"DiO4uhHEiI6st78cJyuLs6" //#define GETUI_APPSECRET @"iFksMbXAyI9hzvd3nVuCk4" //#else #define GETUI_APPID @"eBTiiKUKSs6krglnAzifZ6" #define GETUI_APPKEY @"4WAxUUYTGR7SjIKmiZJQF4" #define GETUI_APPSECRET @"ZWKYAXUTqH8ZrxWZ3mSBG2" //#endif #define BUGLY_APPID @"2e3a9a4d2f" #define APPSTORE_APPID @"6443752990" #define UNIVERSAL_LINK @"https://h5.diandi.club/appconnect/hole/" #define UM_SHARE_REDIRECT_URL @"http://mobile.umeng.com/social" #define WEIXIN_APP_ID @"wx3ba78d0f0f56fbc6" #define WEIXIN_APP_SECRET @"c99e4ab21782aa753bad2cb89bf86999" #define QQ_APP_ID @"1109886623" #define QQ_APP_SECRET @"a589013f1350bc9566841324e053d356" #define UM_SHARE_APP_KEY @"633fecec88ccdf4b7e4097a8" //个推推送 //#define iPhoneX 弃用,后面还有iPhoneXs iPhoneXr 等新设备 #define STATUS_BAR_HEIGHT STATUSBAR_HEIGHT #define SCREEN_WIDTH getScreenWidth() #define SCREEN_HEIGHT getScreenHeight() #define NAVIGATION_BAR_HEIGHT (STATUS_BAR_HEIGHT + 44) #define TAB_BAR_HEIGHT (controllerToolbarHeight()) #define CGRectCombine(point,size) CGRectMake(point.x,point.y,size.width,size.height) #define WeakSelf(type) __weak typeof(type) weak##type = type #define StrongSelf(type) __strong typeof(type) type = weak##type // FIX #define FIX_SIZE(s) lrintf((s * SCREEN_WIDTH / 375.0f)) //#define BottleCollectionCellWidth (SCREEN_WIDTH/5.0f) //#define FIX_SIZE(s) (s) #define THEME_COLOR COLOR_WITH_RGB(0xFFBE00) #define TITLE_COLOR COLOR_WITH_RGB(0xFFFFFF) #define CONTENT_COLOR COLOR_WITH_RGB(0xB3B3B3) #define BG_COLOR COLOR_WITH_RGB(0x15112D) #define SUB_BG_COLOR COLOR_WITH_RGB(0x2D2F42) #define LINE_COLOR COLOR_WITH_RGB_A(0xFFFFFF, 0.1) #define NORMAL_SPACE FIX_SIZE(15) #define SMALL_SPACE FIX_SIZE(10) //系统字体宏 #define FONT_SIZE(s) [UIFont systemFontOfSize:(FIX_SIZE(s))] #define FONT_BOLD_SIZE(s) [UIFont boldSystemFontOfSize:(FIX_SIZE(s))] #define FONT_NAME_SIZE(n,s) [UIFont fontWithName:n size:(FIX_SIZE(s))] #define BIG_FONT MT_FONT_REGULAR_SIZE(21) #define NORMAL_FONT MT_FONT_REGULAR_SIZE(15) #define SMALL_FONT MT_FONT_REGULAR_SIZE(13) #define SMALL_11_FONT MT_FONT_REGULAR_SIZE(11) #define BIG_MEDIUM_FONT MT_FONT_MEDIUM_SIZE(21) #define NORMAL_MEDIUM_FONT MT_FONT_MEDIUM_SIZE(15) #define SMALL_MEDIUM_FONT MT_FONT_MEDIUM_SIZE(13) //app 自定义字体 按照屏幕缩放 #define MT_FONT_REGULAR_SIZE(s) ([UIFont fontWithName:@"PingFang-SC-Regular" size:(FIX_SIZE(s))]?: FONT_SIZE(s)) #define MT_FONT_MEDIUM_SIZE(s) ([UIFont fontWithName:@"PingFang-SC-Medium" size:(FIX_SIZE(s))]?: FONT_SIZE(s)) //#define MT_FONT_MEDIUM_SIZE(s) MT_FONT_Heavy_SIZE(s) #define MT_FONT_BOLD_SIZE(s) MT_FONT_ALIBABA_SIZE(s) #define MT_FONT_ALIBABA_SIZE(s) ([UIFont fontWithName:@"Alibaba PuHuiTi 2.0" size:(FIX_SIZE(s))]?: FONT_BOLD_SIZE(s)) #define MT_FONT_Heavy_SIZE(s) ([UIFont fontWithName:@"PingFang-SC-Heavy" size:(FIX_SIZE(s))]?: FONT_BOLD_SIZE(s)) //字体大小不按照屏幕缩放 #define MT_FONT_REGULAR_NO_SCALE_SIZE(s) ([UIFont fontWithName:@"PingFang-SC-Regular" size:((s))] ?: [UIFont systemFontOfSize:s]) #define MT_FONT_MEDIUM_NO_SCALE_SIZE(s) ([UIFont fontWithName:@"PingFang-SC-Medium" size:((s))] ?: [UIFont systemFontOfSize:s]) #define MT_FONT_BOLD_NO_SCALE_SIZE(s) ([UIFont fontWithName:@"PingFangTC-Semibold" size:((s))] ?: [UIFont boldSystemFontOfSize:s]) // COLOR #define RGB(r,g,b) [UIColor colorWithRed:r/255.0 green:g/255.0 blue:b/255.0 alpha:1] #define RGBA(r,g,b,a) [UIColor colorWithRed:r/255.0 green:g/255.0 blue:b/255.0 alpha:a] #define ShortColor(x) [UIColor colorWithRed:x/255.0 green:x/255.0 blue:x/255.0 alpha:1] #define COLOR_WITH_RGB(hex) [UIColor colorWithRed:((hex & 0x00FF0000) >> 16)/255.0f green:((hex & 0x0000FF00) >> 8)/255.0f blue:(hex & 0x000000FF)/255.0f alpha:1.0] #define COLOR_WITH_RGB_A(hex, a) [UIColor colorWithRed:((hex & 0x00FF0000) >> 16)/255.0f green:((hex & 0x0000FF00) >> 8)/255.0f blue:(hex & 0x000000FF)/255.0f alpha:(a)] #define HEX_COLOR(hex) [UIColor colorWithRed:((hex & 0x00FF0000) >> 16)/255.0f green:((hex & 0x0000FF00) >> 8)/255.0f blue:(hex & 0x000000FF)/255.0f alpha:1.0] #define HEX_COLOR_A(hex, a) [UIColor colorWithRed:((hex & 0x00FF0000) >> 16)/255.0f green:((hex & 0x0000FF00) >> 8)/255.0f blue:(hex & 0x000000FF)/255.0f alpha:(a)] // IMAGE #define ImageNamed(n) [UIImage imageNamed:n] #define ImageforPath(p) [UIImage imageWithContentsOfFile:p] #define PYPlaceholderImage ImageNamed(@"placeholderimage") #define PYDefaultAvatarImage ImageNamed(@"TH_boy_def_img") #define PYTableLoadPerPageCount 10 #import "CYH_PrefixHeader.h" #import "ZcqVender.h"//zcq自己工具. #import "UIScreenEx.h" #import "UIViewAdditions.h" #import "MJExtension.h" #import "UIColor+PYExtension.h" #import "SVProgressHUD.h" #import "UIImage+TintColor.h" //#import "PYWebController.h" #import "UITextField+MTLimit.h" #import "PYAppService.h" #import #import "PYThemeButton.h" #import "PYImageView.h" #import "MTAlertView.h" #import "MTPageView.h" #import "PYHTTPManager.h" #import "MJExtension.h" #import "PYNavigationViewController.h" #import "NSDictionary+Json.h" #import "NSString+PYExtension.h" //#import "AmountKeyboard.h" #import "UserService.h" #import "UIView+MTCreate.h" #import "LoginService.h" #import "AvatarView.h" #import "ToastUtil.h" #import "UIImage+Scale.h" //约束 #import #import //#import "UIView+PYExtension.h" #define DicFromJsonString(jsonString) [NSDictionary dictionaryWithJsonString:jsonString] #endif /* PrefixHeader_pch */