iOS 的圆形计时器 - KVTimer
##安装
下载项目,并将文件 添加到您的项目中。
##使用方式
/*Create its Outlet -*/ @property (weak, nonatomic) IBOutlet KVTimer *timer;
self.timer.delegate = self;
[self.timer setShowTimerLabel:YES];
[self.timer setMaxTime:120 minTime:0];
self.timer.interval = KVIntervalSecond;
KVStyle *style = [KVStyle initWithFillColor:[UIColor greenColor]
strokeColor:[UIColor blackColor]
lineWidth:2
radius:10];
[self.timer setStylePin:<#(KVStyle *)#>]
[self.timer setStyleLine:<#(KVStyle *)#>]
[self.timer setStyleCircle:<#(KVStyle *)#>]
[self.timer startTimer:/* YES / NO */];
####new
[self.timer setShowTimerLabel:/* YES / NO*/];
[self.timer setShowKofLabel:/* YES / NO*/];
[self.timer setKofString:@"min"];
[self.timer setInterval:KVIntervalMinute /*(KVInterval enum)*/];
###方法代理
- (void)getTimer:(NSString *)time{
NSLog(@"Time: %@", time);
}
- (void)endTime{
NSLog(@"Oops");
}
####new - (void)stopTimer{ NSLog(@"Ok"); }
Vlad Kochergin, [email protected]
KVTimer 可在 MIT 许可证下使用。有关更多信息,请参阅 LICENSE 文件。