阅读 15

WBLoadingIndicatorView(加载等待动画)

中文说明





基于CALayer封装加载等待动画,目前支持6种类型动画:

typedef NS_ENUM(NSInteger, WBLoadingAnimationType) {
WBLoadingAnimationcircleStrokeSpinType,
WBWBLoadingAnimationBallPulseType,
WBWBLoadingAnimationBallClipRotateType,
WBWBLoadingAnimationBallClipRotatePulseType,
WBWBLoadingAnimationBallClipRotateMultipleType,
WBWBLoadingAnimationBallTrianglePathType,
WBLoadingAnimationBallSurround
};
复制代码

Requirements

  • iOS 8+
  • Xcode 8+

Installation

Cocoapods安装

WBLoadingIndicatorView is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'WBLoadingIndicatorView'
复制代码

手动安装

WBLoadingIndicatorView文件夹拖入工程即可。

Usage

  • 使用示例
WBLoadingIndicatorView *indicatorView = [WBLoadingIndicatorView wb_showIndicatorAddTo:self.view];
indicatorView.type = WBLoadingAnimationBallSurround;
indicatorView.indicatorSize = CGSizeMake(45, 45);
indicatorView.backgroundView.backgroundColor = [UIColor whiteColor];
indicatorView.bezelView.style = WBLoadingIndicatorBackgroundSolidStyle;
indicatorView.bezelView.backgroundColor = [UIColor clearColor];
indicatorView.indicatorColor = [UIColor orangeColor];
复制代码

Author

author:wenbo
QQ:1050794513
email:1050794513@qq.com

更新

  • 2018-09-16 (1.1.1):重构,添加WBLoadingAnimationBallSurround动画
  • 2018-09-11 (1.0.1):添加背景模糊效果

License

WBLoadingIndicatorView is available under the MIT license. See the LICENSE file for more info.

关注下面的标签,发现更多相似文章
评论