YBIBTopView.h 1012 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. //
  2. // YBIBTopView.h
  3. // YBImageBrowserDemo
  4. //
  5. // Created by 波儿菜 on 2019/7/6.
  6. // Copyright © 2019 杨波. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. NS_ASSUME_NONNULL_BEGIN
  10. typedef NS_ENUM(NSInteger, YBIBTopViewOperationType) {
  11. YBIBTopViewOperationTypeSave, //保存
  12. YBIBTopViewOperationTypeMore //更多
  13. };
  14. @interface YBIBTopView : UIView
  15. /// 页码标签
  16. @property (nonatomic, strong, readonly) UILabel *pageLabel;
  17. /// 操作按钮(自定义:直接修改图片或文字,然后添加点击事件)
  18. @property (nonatomic, strong, readonly) UIButton *operationButton;
  19. /// 按钮类型
  20. @property (nonatomic, assign) YBIBTopViewOperationType operationType;
  21. /**
  22. 设置页码
  23. @param page 当前页码
  24. @param totalPage 总页码数
  25. */
  26. - (void)setPage:(NSInteger)page totalPage:(NSInteger)totalPage;
  27. /// 点击操作按钮的回调
  28. @property (nonatomic, copy) void(^clickOperation)(YBIBTopViewOperationType type);
  29. + (CGFloat)defaultHeight;
  30. @end
  31. NS_ASSUME_NONNULL_END