不墨迹直接上代码:
.h
#import <Foundation/Foundation.h>
typedef void (^TipsDismissBlock)(void);
@interface CH_Tips : NSObject
+ (void)showTitle:(NSString *)title content:(NSString *)contentText dismissBlock:(TipsDismissBlock)dismissBlock;
@end
.m
@interface CH_Tips ()
@property (nonatomic, strong) TipsDismissBlock dismissBlock;
@end
@implementation CH_Tips
@end