75d24c15
yangbin
123
|
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
61
62
63
|
//
// LoaderTypes.swift
// LoaderButton
//
// Created by 黄进文 on 2018/6/11.
// Copyright © 2018年 Jovins. All rights reserved.
//
import UIKit
public enum LoaderType: Int {
/// 0.rotateChase
case rotateChase
/// 1.lineFade
case lineFade
/// 2.circleStroke
case circleChasse
/// 3.clipRotate
case circleNarrow
/// 4.ballPulse
case ballPulse
/// 5.ballPulseRotate
case ballPulseRotate
/// 6.ballMultipleRotate
case ballMultipleRotate
/// 7.ballRotate
case ballRotate
/// 8.ballBeat
case ballBeat
/// 9.pacman
case pacman
/// 10.circleRotate
case circleRotate
func animation() -> LoaderButtonAnimationDelegate {
switch self {
case .rotateChase:
return LoaderRotateChaseAnimation() /// 0.rotateChase
case .lineFade:
return LoaderLineFadeAnimation() /// 1.lineFade
case .circleChasse:
return LoaderCircleChaseAnimation() /// 2.circleChasse
case .circleNarrow:
return LoaderCircleNarrowAnimation() /// 3.circleNarrow
case .ballPulse:
return LoaderBallPulseAnimation() /// 4.ballPulse
case .ballPulseRotate:
return LoaderBallPulseRotateAnimation() /// 5.ballPulseRotate
case .ballMultipleRotate:
return LoaderBallMultipleRotateAnimation() /// 6.ballMultipleRotate
case .ballRotate:
return LoaderBallRotateAnimation() /// 7.ballRotate
case .ballBeat:
return LoaderBallBeatAnimation() /// 8.ballBeat
case .pacman:
return LoaderPacmanAnimation() /// 9.pacman
case .circleRotate:
return LoaderCircleRotateAnimation() /// 10.circleRotate
}
}
}
|