Latest 0.1.0
Homepage https://github.com/KochIK/KVAlert
License MIT
Platforms ios 7.0
Authors

Easy implementation of alerts – KVAlert

Installation

Using CocoaPods

KVAlert is available through CocoaPods, to install
it simply add the following line to your Podfile:

pod "KVAlert"

Manual

Download the project and add the files KVAlert.{h,m} to your project.

Usage

[KVAlert alertWithTitle:@"Title" message:@"Message" buttons:@[@"First", @"Second"] preferredStyle:UIAlertControllerStyleAlert 
completion:^(NSUInteger buttonPresed) {
  NSLog(@"Alert With Buttons - Close");
  switch (buttonPresed) 
  {
    case 0:
       NSLog(@"tFirst button pressed");
       break;
    case 1:
       NSLog(@"tSecond button pressed");
       break;
  }
}];

Methods

+ (void)alertWithTitle:(NSString *)title 
               message:(NSString *)message 
        preferredStyle:(UIAlertControllerStyle)preferredStyle  
            completion:(KVAlertResponse)completion;

+ (void)alertWithTitle:(NSString *)title 
               message:(NSString *)message 
               buttons:(NSArray *)buttons 
        preferredStyle:(UIAlertControllerStyle)preferredStyle 
            completion:(KVAlertWithButton)completion;

+ (void)alertWithTitle:(NSString *)title 
               message:(NSString *)message 
               buttons:(NSArray *)buttons 
             textField:(NSArray  <UITextField *> *)textField 
            completion:(KVAlertWithTextField)completion;

Author

Vlad Kochergin, [email protected]

License

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

Latest podspec

{
    "name": "KVAlert",
    "version": "0.1.0",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "homepage": "https://github.com/KochIK/KVAlert",
    "authors": {
        "Vlad Kochergin": "[email protected]"
    },
    "summary": "Easy implementation of alerts - KVTimer",
    "source": {
        "git": "https://github.com/KochIK/KVAlert.git",
        "tag": "0.1.0"
    },
    "platforms": {
        "ios": "7.0"
    },
    "source_files": "Classes/*.{h,m}",
    "ios": {
        "frameworks": "UIKit"
    }
}

Pin It on Pinterest

Share This