Latest 1.0.2
Homepage https://github.com/dlfkid/iOSDeviceScreenAdapter
License MIT
Platforms ios 10.0, requires ARC
Frameworks Foundation, UIKit
Authors

A simple class that help you identify device’s screen when coding, with some useful extensions inside.

All method are implemented as class methods, It may seem easier to use.

Now with CocoaPods compatible

Install Manually:

  1. Simply copy the class file into your project.

  2. import the header file.

Install with CocoaPods:

  1. add this line into your Podfile:

    pod ‘iOSDeviceScreenAdapter’, ‘~> 1.0.2’

  2. pod install

  3. import the framework with

    import <iOSDeviceScreenAdapter/DeviceScreenAdapter>

Methods Available:

alt text

Latest podspec

{
    "name": "iOSDeviceScreenAdapter",
    "version": "1.0.2",
    "summary": "A simple class that help you identify device's screen when coding, with some useful extensions inside",
    "description": "A simple class that help you identify device's screen when coding, with some useful extensions insiden                  /**n get singleton instancenn @return the shared screen adaptorn */n+ (DeviceScreenAdaptor *)sharedAdaptor;nnn/**n transfer the UI value to adapt other screennn @param standardValue the value you used when coding with your develop iOS device.n @return the transfered value when running in other screen type devices.n */n+ (CGFloat)adaptedValue:(CGFloat)standardValue;nnn/**n simply tell you wether the screen is in landscape.nn @return the screen is currently landscape or notn */n+ (BOOL)isLandscape;nnn/**n the screen type of current devicenn @return predefined screen type enumn */n+ (DeviceScreenType)screenType;nnn/**n the type of the  current devicenn @return predefined device type enumn */n+ (DeviceType)deviceType;nnn/**n the device type in string classnn @return device type stringn */n+ (NSString *)deviceTypeString;nn/**n return the height of statusBar, NAVIGATIONBAR HEIGHT NOT INCLUDEDnn @return status bar heightn */n+ (CGFloat)statusBarMargin;nnn/**n return the height of bottom indicatornn @return bottom indocatorn */n+ (CGFloat)bottomIndicatorMargin;",
    "homepage": "https://github.com/dlfkid/iOSDeviceScreenAdapter",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "IvanDeng": "[email protected]"
    },
    "source": {
        "git": "https://github.com/dlfkid/iOSDeviceScreenAdapter.git",
        "tag": "1.0.2"
    },
    "source_files": "ScreenAdapterDemo/ScreenAdapterDemo/ScreenAdapter/*.{h,m}",
    "requires_arc": true,
    "platforms": {
        "ios": "10.0"
    },
    "frameworks": [
        "Foundation",
        "UIKit"
    ]
}

Pin It on Pinterest

Share This