-
Notifications
You must be signed in to change notification settings - Fork 8
/
SDCycleScrollView.h
executable file
·60 lines (42 loc) · 2.02 KB
/
SDCycleScrollView.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
//
// SDCycleScrollView.h
// SDCycleScrollView
//
// Created by aier on 15-3-22.
// Copyright (c) 2015年 GSD. All rights reserved.
//
/**
*******************************************************
* *
* 感谢您的支持, 如果下载的代码在使用过程中出现BUG或者其他问题 *
* 您可以发邮件到[email protected] 或者 到 *
* https://github.com/gsdios?tab=repositories 提交问题 *
* *
*******************************************************
*/
#import <UIKit/UIKit.h>
typedef enum {
SDCycleScrollViewPageContolAlimentRight,
SDCycleScrollViewPageContolAlimentCenter
} SDCycleScrollViewPageContolAliment;
@class SDCycleScrollView;
@protocol SDCycleScrollViewDelegate <NSObject>
- (void)cycleScrollView:(SDCycleScrollView *)cycleScrollView didSelectItemAtIndex:(NSInteger)index;
@end
@interface SDCycleScrollView : UIView
@property (nonatomic, strong) NSArray *localizationImagesGroup; // 本地图片数组
@property (nonatomic, strong) NSArray *imageURLsGroup;
@property (nonatomic, strong) NSArray *titlesGroup;
@property (nonatomic, assign) CGFloat autoScrollTimeInterval;
@property (nonatomic, weak) id<SDCycleScrollViewDelegate> delegate;
// 自定义样式
@property (nonatomic, assign) SDCycleScrollViewPageContolAliment pageControlAliment; // 分页控件位置
@property (nonatomic, assign) CGSize pageControlDotSize; // 分页控件小圆标大小
@property (nonatomic, strong) UIColor *dotColor; // 分页控件小圆标颜色
@property (nonatomic, strong) UIColor *titleLabelTextColor;
@property (nonatomic, strong) UIFont *titleLabelTextFont;
@property (nonatomic, strong) UIColor *titleLabelBackgroundColor;
@property (nonatomic, assign) CGFloat titleLabelHeight;
+ (instancetype)cycleScrollViewWithFrame:(CGRect)frame imagesGroup:(NSArray *)imagesGroup;
+ (instancetype)cycleScrollViewWithFrame:(CGRect)frame imageURLsGroup:(NSArray *)imageURLsGroup;
@end