RatingBar.h 830 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. //
  2. // RatingBar.h
  3. // MyRatingBar
  4. //
  5. // Created by Leaf on 14-8-28.
  6. // Copyright (c) 2014年 Leaf. All rights reserved.
  7. //
  8. // 版权属于原作者
  9. // http://code4app.com (cn) http://code4app.net (en)
  10. // 发布代码于最专业的源码分享网站: Code4App.com
  11. #import <UIKit/UIKit.h>
  12. @interface RatingBar : UIView
  13. {
  14. MyBlockType starNumBlock;
  15. }
  16. /**
  17. *设置星星数量
  18. */
  19. @property (nonatomic,assign) NSInteger starNumber;
  20. /**
  21. *调整底部视图的颜色
  22. */
  23. @property (nonatomic,strong) UIColor *viewColor;
  24. /**
  25. *是否允许可触摸
  26. */
  27. @property (nonatomic,assign) BOOL enable;
  28. /**
  29. 初始化
  30. @param frame
  31. @param flag 标志位,if flag = 1,star左边对齐(无空格)
  32. @return
  33. */
  34. - (id)initWithFrame:(CGRect)frame Flag:(BOOL)flag;
  35. - (void)changeStarNumberBlock:(MyBlockType)starBlock;
  36. @end