/HDNotificationView

Emulates the native Notification Banner UI for any alert.

Primary LanguageObjective-CMIT LicenseMIT

Introduction

HDNotificationView appears notification view like system.

alt tag alt tag

Requirement

  • iOS 8.0+

Installation

Add two files HDNotificationView.h and HDNotificationView.m to your project.

Go ahead and import HDNotificationView to your file.

#import "HDNotificationView.h"

Usage

Show notification view with image (icon), title and message

+ (void)showNotificationViewWithImage:(UIImage *)image 
                                title:(NSString *)title 
                              message:(NSString *)message;     /// isAutoHide = YES

+ (void)showNotificationViewWithImage:(UIImage *)image 
                                title:(NSString *)title 
                              message:(NSString *)message
                           isAutoHide:(BOOL)isAutoHide;       /// onTouch = nil
                           
+ (void)showNotificationViewWithImage:(UIImage *)image
                                title:(NSString *)title 
                              message:(NSString *)message 
                           isAutoHide:(BOOL)isAutoHide 
                              onTouch:(void (^)())onTouch;

Hide notification view

+ (void)hideNotificationView;

+ (void)hideNotificationViewOnComplete:(void (^)())onComplete;

License

HDNotificationView is available under the MIT License. See the LICENSE for details.