
@ -0,0 +1,147 @@ |
|||||||
|
<?xml version="1.0" encoding="UTF-8"?> |
||||||
|
<Bucket |
||||||
|
uuid = "FB9FE57D-A05C-4F25-A025-8FAD3B37C2C9" |
||||||
|
type = "0" |
||||||
|
version = "2.0"> |
||||||
|
<Breakpoints> |
||||||
|
<BreakpointProxy |
||||||
|
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint"> |
||||||
|
<BreakpointContent |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
filePath = "FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
landmarkName = "fb_titleLabel" |
||||||
|
landmarkType = "24"> |
||||||
|
<Locations> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 505b34cd7c13c27a" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.fb_titleLabel.getter : __C.UILabel" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "156"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 8a693b7dabf4100e" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "closure #1 () -> __C.UILabel in FireBoltt.HealthStepCell.fb_titleLabel.getter : __C.UILabel" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "14" |
||||||
|
endingLineNumber = "14" |
||||||
|
offsetFromSymbolStart = "24"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 423a503f08182e4e" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.fb_titleLabel.setter : __C.UILabel" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "108"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - a757aa22d42d1b7d" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.fb_titleLabel.modify : __C.UILabel" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "0"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 3373665130b7f94e" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.fb_titleLabel.modify : __C.UILabel with unmangled suffix ".resume.0"" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "20"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 57ddc4614a5b5a49" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.init(style: __C.UITableViewCellStyle, reuseIdentifier: Swift.Optional<Swift.String>) -> FireBoltt.HealthStepCell" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "168"> |
||||||
|
</Location> |
||||||
|
<Location |
||||||
|
uuid = "2606C474-3C07-44B7-9566-F88837835AE5 - 8b601723f0524b57" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
symbolName = "FireBoltt.HealthStepCell.init(coder: __C.NSCoder) -> Swift.Optional<FireBoltt.HealthStepCell>" |
||||||
|
moduleName = "FireBoltt" |
||||||
|
usesParentBreakpointCondition = "Yes" |
||||||
|
urlString = "file:///Users/ecell/FireBoltt_ios/FireBoltt/FB_Modules/FB_Health/View/HealthStepCell.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "13" |
||||||
|
endingLineNumber = "13" |
||||||
|
offsetFromSymbolStart = "144"> |
||||||
|
</Location> |
||||||
|
</Locations> |
||||||
|
</BreakpointContent> |
||||||
|
</BreakpointProxy> |
||||||
|
<BreakpointProxy |
||||||
|
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint"> |
||||||
|
<BreakpointContent |
||||||
|
uuid = "0F0451D5-6F0D-4617-8E19-BA98338D2957" |
||||||
|
shouldBeEnabled = "Yes" |
||||||
|
ignoreCount = "0" |
||||||
|
continueAfterRunningActions = "No" |
||||||
|
filePath = "FireBoltt/FB_Modules/FB_My/Controller/MineViewController.swift" |
||||||
|
startingColumnNumber = "9223372036854775807" |
||||||
|
endingColumnNumber = "9223372036854775807" |
||||||
|
startingLineNumber = "54" |
||||||
|
endingLineNumber = "54" |
||||||
|
landmarkName = "makeUI()" |
||||||
|
landmarkType = "7"> |
||||||
|
</BreakpointContent> |
||||||
|
</BreakpointProxy> |
||||||
|
</Breakpoints> |
||||||
|
</Bucket> |
@ -0,0 +1,58 @@ |
|||||||
|
// |
||||||
|
// DeviceFooterView.swift |
||||||
|
// FireBoltt |
||||||
|
// |
||||||
|
// Created by ecell on 2023/9/13. |
||||||
|
// Copyright © 2023 Sheldon. All rights reserved. |
||||||
|
// |
||||||
|
|
||||||
|
import UIKit |
||||||
|
|
||||||
|
class DeviceFooterView: UIView { |
||||||
|
|
||||||
|
lazy var unBindingBtn: UIButton = { |
||||||
|
let btn = UIButton(type: .custom).then { |
||||||
|
$0.setTitle(MultiLanguageKey_FB.unBindingFB.localized, for: .normal) |
||||||
|
$0.setTitleColor(.white, for: .normal) |
||||||
|
$0.titleLabel?.font = SystemRegularFont(18) |
||||||
|
} |
||||||
|
btn.gradient(colors: [kHexColor(0x59AAFF), kHexColor(0x2B75FF)], startPoint: CGPoint(x: 0, y: 0.5), endPoint: CGPoint(x: 1, y: 0.5), locations: [0, 1], autoLaoutFrame: CGRect(x: 0, y: 0, width: self.frame.size.width-40, height: kScaleWidth(50))) |
||||||
|
btn.layer.cornerRadius = kScaleWidth(25) |
||||||
|
btn.layer.masksToBounds = true |
||||||
|
return btn |
||||||
|
}() |
||||||
|
|
||||||
|
override init(frame: CGRect) { |
||||||
|
super.init(frame: frame) |
||||||
|
self.addSubview(unBindingBtn) |
||||||
|
setUpUI() |
||||||
|
} |
||||||
|
|
||||||
|
func setUpUI() { |
||||||
|
unBindingBtn.snp.makeConstraints { make in |
||||||
|
make.left.right.equalTo(self).inset(20) |
||||||
|
make.centerY.equalTo(self) |
||||||
|
make.height.equalTo(kScaleWidth(50)); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
required init?(coder: NSCoder) { |
||||||
|
fatalError("init(coder:) has not been implemented") |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* |
||||||
|
// Only override draw() if you perform custom drawing. |
||||||
|
// An empty implementation adversely affects performance during animation. |
||||||
|
override func draw(_ rect: CGRect) { |
||||||
|
// Drawing code |
||||||
|
} |
||||||
|
*/ |
||||||
|
|
||||||
|
} |
@ -0,0 +1,30 @@ |
|||||||
|
//
|
||||||
|
// UIColor+Extension.h
|
||||||
|
// XFGradientProgressView
|
||||||
|
//
|
||||||
|
// Created by XFCoding on 2020/5/12.
|
||||||
|
// Copyright © 2020 XFCoding. All rights reserved.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <UIKit/UIKit.h> |
||||||
|
NS_ASSUME_NONNULL_BEGIN |
||||||
|
@interface UIColor (Extension) |
||||||
|
/**
|
||||||
|
* 两个颜色之间的过渡颜色 |
||||||
|
* beginColor 开始颜色 |
||||||
|
* endColor 结束颜色 |
||||||
|
* position 过渡的比例 (0~1) |
||||||
|
*/ |
||||||
|
+ (UIColor *)transitionColorWithStartColor:(UIColor *)startColor endColor:(UIColor *)endColor position:(CGFloat )position; |
||||||
|
|
||||||
|
/**
|
||||||
|
* 取两个颜色的过渡颜色 |
||||||
|
* startColorHex 开始颜色的 十六进制值 |
||||||
|
* endColorHex 结束颜色的 十六进制值 |
||||||
|
* position 过渡比例 (0~1) |
||||||
|
*/ |
||||||
|
+ (UIColor *)transitionColorWithStartColorHex:(unsigned int)startColorHex endColorHex:(unsigned int)endColorHex position:(CGFloat )position; |
||||||
|
|
||||||
|
@end |
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END |
@ -0,0 +1,66 @@ |
|||||||
|
// |
||||||
|
// UIColor+Extension.m |
||||||
|
// XFGradientProgressView |
||||||
|
// |
||||||
|
// Created by XFCoding on 2020/5/12. |
||||||
|
// Copyright © 2020 XFCoding. All rights reserved. |
||||||
|
// |
||||||
|
|
||||||
|
#import "UIColor+Extension.h" |
||||||
|
|
||||||
|
@implementation UIColor (Extension) |
||||||
|
|
||||||
|
+ (UIColor *)colorWithHexColor:(unsigned int)hexColor { |
||||||
|
return [UIColor colorWithRed:((hexColor>>16)&0xFF)/255.0 green:((hexColor>>8)&0xFF)/255.0 blue:(hexColor&0xFF)/255.0 alpha:1.0]; |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 两个颜色之间的过渡颜色 |
||||||
|
* beginColor 开始颜色 |
||||||
|
* endColor 结束颜色 |
||||||
|
* position 过渡的比例 (0~1) |
||||||
|
*/ |
||||||
|
+ (UIColor *)transitionColorWithStartColor:(UIColor *)startColor endColor:(UIColor *)endColor position:(CGFloat )position { |
||||||
|
UIColor *desColor = nil; |
||||||
|
// 获取开始位置颜色的 R、G、B、A值 |
||||||
|
CGFloat startR = 0; |
||||||
|
CGFloat startG = 0; |
||||||
|
CGFloat startB = 0; |
||||||
|
CGFloat startA = 0; |
||||||
|
[startColor getRed:&startR green:&startG blue:&startB alpha:&startA]; |
||||||
|
|
||||||
|
// 获取结束位置颜色的 R、G、B、A值 |
||||||
|
CGFloat endR = 0; |
||||||
|
CGFloat endG = 0; |
||||||
|
CGFloat endB = 0; |
||||||
|
CGFloat endA = 0; |
||||||
|
[endColor getRed:&endR green:&endG blue:&endB alpha:&endA]; |
||||||
|
|
||||||
|
CGFloat R = (endR - startR)*position + startR; |
||||||
|
CGFloat G = (endG - startG)*position + startG; |
||||||
|
CGFloat B = (endB - startB)*position + startB; |
||||||
|
CGFloat A = (endA - startA)*position + startA; |
||||||
|
|
||||||
|
//根据当前位置获取当前应该要展示的颜色值 |
||||||
|
desColor = [UIColor colorWithRed:R green:G blue:B alpha:A]; |
||||||
|
|
||||||
|
return desColor; |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 取两个颜色的过渡颜色 |
||||||
|
* startColorHex 开始颜色的 十六进制值 |
||||||
|
* endColorHex 结束颜色的 十六进制值 |
||||||
|
* position 过渡比例 (0~1) |
||||||
|
*/ |
||||||
|
+ (UIColor *)transitionColorWithStartColorHex:(unsigned int)startColorHex endColorHex:(unsigned int)endColorHex position:(CGFloat )position { |
||||||
|
return [self transitionColorWithStartColor:[self colorWithHexColor:startColorHex] endColor:[self colorWithHexColor:endColorHex] position:position]; |
||||||
|
|
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@end |
||||||
|
|
@ -0,0 +1,33 @@ |
|||||||
|
//
|
||||||
|
// XFGradientProgressView.h
|
||||||
|
// XFGradientProgressView
|
||||||
|
//
|
||||||
|
// Created by XFCoding on 2020/5/12.
|
||||||
|
// Copyright © 2020 XFCoding. All rights reserved.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <UIKit/UIKit.h> |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@interface XFGradientProgressView : UIView |
||||||
|
|
||||||
|
/// 初始化进度条
|
||||||
|
/// @param frame ~
|
||||||
|
/// @param startColor 起始颜色
|
||||||
|
/// @param endColor 结束颜色
|
||||||
|
/// @param backProgressColor 进度条背景颜色
|
||||||
|
- (instancetype)initWithFrame:(CGRect)frame startColor:(UIColor *)startColor endColor:(UIColor *)endColor backProgressColor:(UIColor *)backProgressColor; |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//设置最终进度(0.0~1.0)和动画时间,动画时间默认1.0s
|
||||||
|
- (void)StartAnimationToProgress:(CGFloat)progress durationTime:(CGFloat)durationTime sImgName:(NSString *)sImgName; |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@end |
||||||
|
|
@ -0,0 +1,167 @@ |
|||||||
|
// |
||||||
|
// XFGradientProgressView.m |
||||||
|
// XFGradientProgressView |
||||||
|
// |
||||||
|
// Created by XFCoding on 2020/5/12. |
||||||
|
// Copyright © 2020 XFCoding. All rights reserved. |
||||||
|
// |
||||||
|
|
||||||
|
#import "XFGradientProgressView.h" |
||||||
|
#import "UIColor+Extension.h" |
||||||
|
|
||||||
|
#define COLOR_HEX(c) [UIColor colorWithRed:((c>>16)&0xFF)/255.0 green:((c>>8)&0xFF)/255.0 blue:(c&0xFF)/255.0 alpha:1.0] |
||||||
|
#define COLOR_RGB(r,g,b) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:1.0] |
||||||
|
|
||||||
|
#define kArcWidth (10.0f) |
||||||
|
#define kArcCenter (CGPointMake(self.bounds.size.width / 2, self.bounds.size.height / 2 + kArcWidth)) |
||||||
|
#define kArcRadius (self.bounds.size.width/2.0) |
||||||
|
#define kStartAngle (3*M_PI_4) |
||||||
|
#define kEndAngle (M_PI_4) |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@interface XFGradientProgressView () |
||||||
|
|
||||||
|
@property (nonatomic, strong) CAShapeLayer *progressLayer; |
||||||
|
@property (nonatomic, strong) CAShapeLayer *progressBackLayer; |
||||||
|
//渐变的起始颜色和结束颜色 |
||||||
|
@property (nonatomic, copy) UIColor *startColor; |
||||||
|
@property (nonatomic, copy) UIColor *endColor; |
||||||
|
//进度条背景颜色 |
||||||
|
@property (nonatomic, copy) UIColor *backProgressColor; |
||||||
|
|
||||||
|
|
||||||
|
@property (nonatomic ,strong) UIImageView *scheduleImg; |
||||||
|
|
||||||
|
@end |
||||||
|
|
||||||
|
@implementation XFGradientProgressView |
||||||
|
|
||||||
|
- (instancetype)initWithFrame:(CGRect)frame startColor:(UIColor *)startColor endColor:(UIColor *)endColor backProgressColor:(UIColor *)backProgressColor{ |
||||||
|
if (self = [super initWithFrame:frame]) { |
||||||
|
self.startColor = startColor; |
||||||
|
self.endColor = endColor; |
||||||
|
self.backProgressColor = backProgressColor; |
||||||
|
[self createProgressBar]; |
||||||
|
} |
||||||
|
return self; |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
生成贝塞尔曲线并设置为shapeLayer的路径 |
||||||
|
*/ |
||||||
|
- (void)createProgressBar { |
||||||
|
[self.layer addSublayer:self.progressBackLayer]; |
||||||
|
[self.layer addSublayer:self.progressLayer]; |
||||||
|
|
||||||
|
UIBezierPath *bPath = [UIBezierPath bezierPathWithArcCenter:kArcCenter radius:kArcRadius startAngle:kStartAngle endAngle:kEndAngle clockwise:YES]; |
||||||
|
self.progressLayer.path = bPath.CGPath; |
||||||
|
self.progressBackLayer.path = bPath.CGPath; |
||||||
|
|
||||||
|
[self createGradientLayer]; |
||||||
|
[self addSubview:self.scheduleImg]; |
||||||
|
|
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
设置色彩渐变图层 |
||||||
|
*/ |
||||||
|
- (void)createGradientLayer { |
||||||
|
CALayer *layer = [CALayer layer]; |
||||||
|
layer.frame = self.bounds; |
||||||
|
|
||||||
|
if (!self.startColor || !self.endColor) { |
||||||
|
self.startColor = COLOR_HEX(0xfb6400); |
||||||
|
self.endColor = COLOR_HEX(0xfc9c00); |
||||||
|
|
||||||
|
} |
||||||
|
UIColor *mediumColor = [UIColor transitionColorWithStartColor:self.startColor endColor:self.endColor position:0.5]; |
||||||
|
|
||||||
|
CAGradientLayer *leftLayer = [CAGradientLayer layer]; |
||||||
|
leftLayer.frame = CGRectMake(-kArcWidth/2, -kArcWidth/2, self.bounds.size.width/2+kArcWidth/2, self.bounds.size.height+kArcWidth/2); |
||||||
|
leftLayer.colors = @[ (id)_startColor.CGColor,(id)mediumColor.CGColor]; |
||||||
|
leftLayer.locations = @[@0,@1]; |
||||||
|
leftLayer.startPoint = CGPointMake(0, 1); |
||||||
|
leftLayer.endPoint = CGPointMake(1, 0); |
||||||
|
|
||||||
|
CAGradientLayer *rightLayer = [CAGradientLayer layer]; |
||||||
|
rightLayer.frame = CGRectMake(self.bounds.size.width/2, -kArcWidth/2, self.bounds.size.width/2+kArcWidth/2, self.bounds.size.height+kArcWidth/2); |
||||||
|
rightLayer.colors = @[ (id)mediumColor.CGColor,(id)_endColor.CGColor]; |
||||||
|
rightLayer.locations = @[@0,@1]; |
||||||
|
rightLayer.startPoint = CGPointMake(0, 0); |
||||||
|
rightLayer.endPoint = CGPointMake(1, 1); |
||||||
|
|
||||||
|
//设置蒙层 |
||||||
|
layer.mask = self.progressLayer; |
||||||
|
[layer addSublayer:leftLayer]; |
||||||
|
[layer addSublayer:rightLayer]; |
||||||
|
[self.layer addSublayer:layer]; |
||||||
|
} |
||||||
|
|
||||||
|
- (void)StartAnimationToProgress:(CGFloat)progress durationTime:(CGFloat)durationTime sImgName:(NSString *)sImgName |
||||||
|
{ |
||||||
|
CGFloat endAngle = kStartAngle + progress*M_PI*3/2; |
||||||
|
UIBezierPath *bPath = [UIBezierPath bezierPathWithArcCenter:kArcCenter radius:kArcRadius startAngle:kStartAngle endAngle:endAngle clockwise:YES]; |
||||||
|
self.progressLayer.path = bPath.CGPath; |
||||||
|
self.scheduleImg.image = [UIImage imageNamed:sImgName]; |
||||||
|
self.scheduleImg.frame = CGRectMake(bPath.currentPoint.x-5, bPath.currentPoint.y-5, 10, 10); |
||||||
|
self.scheduleImg.center = bPath.currentPoint; |
||||||
|
NSLog(@"%f--%f",bPath.currentPoint.x,bPath.currentPoint.y); |
||||||
|
|
||||||
|
CAKeyframeAnimation *keyAnimation = [CAKeyframeAnimation animationWithKeyPath:@"strokeEnd"]; |
||||||
|
keyAnimation.values = @[@0.0,@1.0]; |
||||||
|
keyAnimation.duration = durationTime; |
||||||
|
[self.progressLayer addAnimation:keyAnimation forKey:nil]; |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
- (CAShapeLayer *)progressLayer { |
||||||
|
if (!_progressLayer) { |
||||||
|
_progressLayer = [CAShapeLayer layer]; |
||||||
|
_progressLayer.fillColor = [UIColor clearColor].CGColor; |
||||||
|
_progressLayer.strokeColor = [UIColor whiteColor].CGColor; |
||||||
|
_progressLayer.lineWidth = kArcWidth; |
||||||
|
_progressLayer.lineCap = kCALineCapRound; |
||||||
|
} |
||||||
|
return _progressLayer; |
||||||
|
} |
||||||
|
|
||||||
|
- (CAShapeLayer *)progressBackLayer { |
||||||
|
if (!_progressBackLayer) { |
||||||
|
_progressBackLayer = [CAShapeLayer layer]; |
||||||
|
_progressBackLayer.fillColor = [UIColor clearColor].CGColor; |
||||||
|
_progressBackLayer.lineWidth = kArcWidth; |
||||||
|
_progressBackLayer.lineCap = kCALineCapRound; |
||||||
|
_progressBackLayer.strokeColor = _backProgressColor?_backProgressColor.CGColor : [UIColor grayColor].CGColor; |
||||||
|
|
||||||
|
} |
||||||
|
return _progressBackLayer; |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
- (UIImageView *)scheduleImg |
||||||
|
{ |
||||||
|
if (!_scheduleImg) |
||||||
|
{ |
||||||
|
_scheduleImg = [UIImageView new]; |
||||||
|
// _scheduleImg.layer.cornerRadius = 5; |
||||||
|
// _scheduleImg.layer.masksToBounds = YES; |
||||||
|
// _scheduleImg.backgroundColor = UIColor.redColor; |
||||||
|
|
||||||
|
} |
||||||
|
return _scheduleImg; |
||||||
|
} |
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@end |
After Width: | Height: | Size: 42 KiB |
After Width: | Height: | Size: 99 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 3.7 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_app_notification@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_app_notification@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 4.3 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_bright_screen@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_bright_screen@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.8 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_call_notification@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_call_notification@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 2.9 KiB |
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.7 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_find@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_find@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.9 KiB |
After Width: | Height: | Size: 4.7 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_hr@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_hr@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 4.1 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_message_notification@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_message_notification@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 3.6 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_music@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_music@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 2.4 KiB |
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 3.4 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 3.3 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 5.2 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_wallet@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_wallet@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 4.0 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "picture_bg@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "picture_bg@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 28 KiB |
After Width: | Height: | Size: 57 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_calories@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_calories@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 632 B |
After Width: | Height: | Size: 1.1 KiB |
@ -0,0 +1,22 @@ |
|||||||
|
{ |
||||||
|
"images" : [ |
||||||
|
{ |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "1x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_distance@2x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "2x" |
||||||
|
}, |
||||||
|
{ |
||||||
|
"filename" : "icon_distance@3x.png", |
||||||
|
"idiom" : "universal", |
||||||
|
"scale" : "3x" |
||||||
|
} |
||||||
|
], |
||||||
|
"info" : { |
||||||
|
"author" : "xcode", |
||||||
|
"version" : 1 |
||||||
|
} |
||||||
|
} |
After Width: | Height: | Size: 567 B |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 691 B |