Latest 1.0.1
Homepage https://github.com/summerxx27/XTAlertViewController
License MIT
Platforms ios 7.0, requires ARC
Authors
XTAlertViewController

preface: Meaning is to create a more versions compatible with similar to UIAlertView controls
pic example:

XTAlertViewController XTAlertViewController XTAlertViewController XTAlertViewController

Gif example:

XTAlertViewController XTAlertViewController

Advantages

  • iOS 7.0 available after
  • Header Image (optional)
  • Title, des (optional)
  • Low coupling (present new controller)
  • Animation with UIKit Dynamics

Features

  • Provide the expansion of the more interesting and powerful features

Cocoapods

  • Add pod 'XTAlertViewController', '~> 1.0.1' to your Podfile
  • Run pod install or pod update –no-repo-update
  • import <XTAlertView.h>

Usage

        // init obj
        XTAlertViewController *xt = [[XTAlertViewController alloc] init];
        // Give a picture name
        // Give a picture's height
        // Give a btn's title array
        // Give a title
        // Give a describtion
        // Give a style  two btn | double btn

        // example 1
        [xt initWithImage:@"summerxx" imageHeight:0 title:@"This is an introduction" btnTitles:@[@"Cancel", @"Determine"] des:@"A simple and easy to use more version using the controls Copyright © 2016年 夏天然后. All rights reserved." style:AlterDefault];
        [self presentViewController:xt animated:YES completion:^{

        }];
        // example 2
        [xt initWithImage:@"summerxx" imageHeight:200 title:@"This is an introduction" btnTitles:@[@"Cancel", @"Determine", @"summerxx"] des:@"A simple and easy to use more version using the controls Copyright © 2016年 夏天然后. All rights reserved." style:AlterDouble];

        // present VC
        [self presentViewController:xt animated:YES completion:^{

        }];

If you use a proxy method

    // Signed an delegate
    @interface ViewController ()<XTAlertControllerDelegate>
    // 
    xt.delegate = self;

Implement delegate method like this

- (void)xt_alertViewControllerClickIndex:(NSInteger)buttonIndex
{

    switch (buttonIndex) {
        case 0:
            NSLog(@"0");
            NSLog(@"Cancel");
        break;
        case 1:
            NSLog(@"1");
            NSLog(@"Determine");
        break;
        case 2:
            NSLog(@"2");
            NSLog(@"summerxx");
        break;
        default:
        break;
    }
}

Contributing

  • If you need help, open an issue.
  • If you found a bug, open an issue.
  • If you have a new demand, also open an issue.

Acknowledgements

Made with by summerxx27 , Thank you for your use

MIT License

XTAlertController is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "XTAlertViewController",
    "version": "1.0.1",
    "license": "MIT",
    "summary": "An view like UIAlertViewController on iOS.",
    "homepage": "https://github.com/summerxx27/XTAlertViewController",
    "authors": {
        "summerxx27": "[email protected]"
    },
    "source": {
        "git": "https://github.com/summerxx27/XTAlertViewController.git",
        "tag": "1.0.1"
    },
    "requires_arc": true,
    "platforms": {
        "ios": "7.0"
    },
    "source_files": "XTAlertViewController/*.{h,m}"
}

Pin It on Pinterest

Share This