Skip to content

Commit

Permalink
Merge pull request gavinkwoe#94 from ganvinalix/master
Browse files Browse the repository at this point in the history
增加iPhone6和iPhone Plus 屏幕检测宏定义
  • Loading branch information
gavinkwoe committed Nov 11, 2014
2 parents 063efff + 0d5c928 commit 55b8e4c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions framework/system/foundation/Bee_SystemInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ AS_PACKAGE( BeePackage_System, BeeSystemInfo, info );
#define IOS4_OR_EARLIER ( !IOS5_OR_LATER )
#define IOS3_OR_EARLIER ( !IOS4_OR_LATER )

#define IS_SCREEN_55_INCH ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1080, 1920), [[UIScreen mainScreen] currentMode].size) : NO)
#define IS_SCREEN_47_INCH ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(750, 1334), [[UIScreen mainScreen] currentMode].size) : NO)
#define IS_SCREEN_4_INCH ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(640, 1136), [[UIScreen mainScreen] currentMode].size) : NO)
#define IS_SCREEN_35_INCH ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(640, 960), [[UIScreen mainScreen] currentMode].size) : NO)

Expand All @@ -68,6 +70,8 @@ AS_PACKAGE( BeePackage_System, BeeSystemInfo, info );

#define IS_SCREEN_4_INCH (NO)
#define IS_SCREEN_35_INCH (NO)
#define IS_SCREEN_47_INCH (NO)
#define IS_SCREEN_55_INCH (NO)

#endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)

Expand Down

0 comments on commit 55b8e4c

Please sign in to comment.