//
// QMetro.h
// QMetro
//
// Created by 博客园.小八究 on 14-10-30.
// Copyright (c) 2014年 NOVO. All rights reserved.
//
// 原文出处:http://www.cnblogs.com/xiaobajiu/p/4084717.html
// 项目还在更新中,故去掉注释,以免误导。提供使用尔。
// 邮箱:quxingyi@outlook.com
#import <UIKit/UIKit.h>
@class QMetro;
@protocol QMetroContainerDelegate <NSObject>
@end
@interface QMetro : UIControl <UIGestureRecognizerDelegate>
{
NSTimer *_timer;
__weak UIView *_container;
double _startDelayRange[2];
int _currentViewID;
CGFloat _keepTimes[2];
CGFloat _turnTimes[2];
NSMutableDictionary *_dictEventKeyTagSELValue;
BOOL _isViewDleaying;
__weak UIView *_maskingView;
}
#pragma mark - 属性
@property (atomic,assign,readonly) BOOL isAnimating;
@property (nonatomic,assign, readonly) BOOL isMetroEventOn;
@property (nonatomic,assign, readonly) BOOL isStopedAnimation;
@property (nonatomic,strong,readonly) NSMutableArray *views;
@property (nonatomic,assign) CGFloat animationTryTime;
@property (nonatomic,assign) CGFloat keepMoreTimeOfViewA;
@property (nonatomic,assign) CGFloat keepMoreTimeOfViewB;
@property (nonatomic,weak) id<QMetroContainerDelegate> delegate;
@property (nonatomic,strong) UIColor *metroThemeColor;
#pragma mark - 方法
- (QMetro*)addView:(UIView*)view;
- (void)removeViewAtIndex:(int)index;
- (void)changeViewAtIndex:(int)index With:(UIView*)view;
- (void)changeViewWhenBackOfMetroByIndex:(int)index With:(UIView*)view;
- (void)beginMetro;
- (void)stopMetro;
- (void)stopAnimation;
- (void)resumeAnimation;
- (void)turnTimeViewA:(double)intervalA ViewB:(double)intervalB;
- (void)delayTimeRandomWhenStartWithMinInterval:(CGFloat)minInterval maxInterval:(CGFloat)maxInterval;
- (void)metroTouchUpInsideTarget:(id)target action:(SEL)action;
- (void)metroAddTarget:(id)target action:(SEL)action forControlEvents:(UIControlEvents)controlEvents;
- (void)metroColorRemove;
- (int)metroCurrentIndex;
@end
评论0
最新资源