MBProgressHUD_NHExtend.h 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. //
  2. // MBProgressHUD_NHExtend.h
  3. // NHHUDExtendDemo
  4. //
  5. // Created by 肖雨 on 2017/8/18.
  6. // Copyright © 2017年 肖雨. All rights reserved.
  7. //
  8. #import "MBProgressHUD.h"
  9. typedef NS_ENUM(NSInteger, NHHUDContentStyle) {
  10. NHHUDContentDefaultStyle = 0,//默认是白底黑字 Default
  11. NHHUDContentBlackStyle = 1,//黑底白字
  12. NHHUDContentCustomStyle = 2,//:自定义风格<由自己设置自定义风格的颜色>
  13. };
  14. typedef NS_ENUM(NSInteger, NHHUDPostion) {
  15. NHHUDPostionTop,//上面
  16. NHHUDPostionCenten,//中间
  17. NHHUDPostionBottom,//下面
  18. };
  19. typedef NS_ENUM(NSInteger, NHHUDProgressStyle) {
  20. NHHUDProgressDeterminate,///双圆环,进度环包在内
  21. NHHUDProgressDeterminateHorizontalBar,///横向Bar的进度条
  22. NHHUDProgressAnnularDeterminate,///双圆环,完全重合
  23. NHHUDProgressCancelationDeterminate,///带取消按钮 - 双圆环 - 完全重合
  24. };
  25. typedef void((^NHCancelation)(MBProgressHUD *hud));
  26. typedef void((^NHCurrentHud)(MBProgressHUD *hud));
  27. @interface MBProgressHUD ()
  28. @property (nonatomic, copy ) NHCancelation cancelation;
  29. ///内容风格
  30. @property (nonatomic, assign, readonly) MBProgressHUD *(^hudContentStyle)(NHHUDContentStyle hudContentStyle);
  31. ///显示位置:有导航栏时在导航栏下在,无导航栏在状态栏下面
  32. @property (nonatomic, assign, readonly) MBProgressHUD *(^hudPostion)(NHHUDPostion hudPostion);
  33. ///进度条风格
  34. @property (nonatomic, assign, readonly) MBProgressHUD *(^hudProgressStyle)(NHHUDProgressStyle hudProgressStyle);
  35. ///标题
  36. @property (nonatomic, copy , readonly) MBProgressHUD *(^title)(NSString *title);
  37. ///详情
  38. @property (nonatomic, copy , readonly) MBProgressHUD *(^details)(NSString *details);
  39. ///自定义图片名
  40. @property (nonatomic, copy , readonly) MBProgressHUD *(^customIcon)(NSString *customIcon);
  41. ///标题颜色
  42. @property (nonatomic, strong, readonly) MBProgressHUD *(^titleColor)(UIColor *titleColor);
  43. ///进度条颜色
  44. @property (nonatomic, strong, readonly) MBProgressHUD *(^progressColor)(UIColor *progressColor);
  45. ///进度条、标题颜色
  46. @property (nonatomic, strong, readonly) MBProgressHUD *(^allContentColors)(UIColor *allContentColors);
  47. ///蒙层背景色
  48. @property (nonatomic, strong, readonly) MBProgressHUD *(^hudBackgroundColor)(UIColor *backgroundColor);
  49. ///内容背景色
  50. @property (nonatomic, strong, readonly) MBProgressHUD *(^bezelBackgroundColor)(UIColor *bezelBackgroundColor);
  51. @end