app引導(dǎo)頁(yè)
作者:wgcq
簡(jiǎn)單實(shí)用的app引導(dǎo)頁(yè),能后在圖片之間漸變切換,最后進(jìn)入主VC.
源碼簡(jiǎn)介:簡(jiǎn)單實(shí)用的app引導(dǎo)頁(yè),能后在圖片之間漸變切換,***進(jìn)入主VC.
源碼效果:
源碼片段:
- 導(dǎo)入ZWIntroductionViewController.h/m文件:
- #import "ZWIntroductionViewController.h"
- - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
- // ...
- // 定制引導(dǎo)頁(yè)的圖片內(nèi)容
- NSArray *coverImageNames = @[@"img_index_01txt", @"img_index_02txt", @"img_index_03txt"];
- NSArray *backgroundImageNames = @[@"img_index_01bg", @"img_index_02bg", @"img_index_03bg"];
- self.introductionView = [[ZWIntroductionViewController alloc] initWithCoverImageNames:coverImageNames backgroundImageNames:backgroundImageNames];
- [self.window addSubview:self.introductionView.view];
- __weak AppDelegate *weakSelf = self;
- self.introductionView.didSelectedEnter = ^() {
- [weakSelf.introductionView.view removeFromSuperview];
- weakSelf.introductionView = nil;
- // enter main view , write your code ...
- //可以在這個(gè)block里面進(jìn)入自己的主VC
- };
- }
責(zé)任編輯:倪明
來(lái)源:
devstore