iOS 呼吸燈效果:RCLighting

jopen 10年前發布 | 34K 次閱讀 iOS開發 移動開發 RCLighting

RCLighting 可在任意view里添加呼吸燈效果,所謂呼吸燈效果,就是顏色和亮度慢慢若隱若現。
支持CocoaPods,pod 'RCLighting'。

Requirements

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.

iOS 呼吸燈效果:RCLighting

項目主頁:http://www.baiduhome.net/lib/view/home/1406473639238

 本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
 轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
 本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!