iOS 呼吸燈效果:RCLighting
RCLighting 可在任意view里添加呼吸燈效果,所謂呼吸燈效果,就是顏色和亮度慢慢若隱若現。
支持CocoaPods,pod 'RCLighting'。
Requirements
- Xcode 5.0 or higher
- iOS 6.0 or higher
- ARC
- pop animation library
Run Example
In your terminal,
cd [workspace]/RCLighting/RCLightingExample
pod install
Then,
open RCLightingExample.xcworkspace
Installation
The recommended approach for installating RCLighting
is via the CocoaPods package manager.
In your Podfile
, add a line shows below:
pod 'RCLighting'
Then,
pod update
Usage
First of all
#import <RCLighting.h>
Show & Remove
Just one line code to show Lighting
, it's very easy to use.
[self.view showLighting]; // That's it!
Default lighting color is view's background color.
Remove Lighting
is as simple as above,
[self.view removeLighting];
Pause & Resume (Debugging)
To pause Lighting
in view,
[self.view pauseLighting];
To resume Lighting
in view,
[self.view resumeLighting];
[animation setPaused:NO]
is not working on POPBasicAnimation
if stop using tracer
debug. I'm work very hard on it. Let me know if you see something.
本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!