ABCIntroView

ABCIntroView is an easy to use onboarding which allows you to introduce your users to the applicaiton before reaching the Main Screen.

ABCIntroView是一个简单易用的引导页。

To use the ABCIntroView please do the following:

你需要遵循以下几步来使用它:

  1. Add the follwing files found in the CLASSES folder to your project: 将以下几个文件拖到你的项目当中:
        *ABCIntroView.h
*ABCIntroView.m
  1. Import the ABCIntoView file to your RootViewController. 将ABCIntoView文件引入到你的RootViewController当中。

  2. Create an ABCIntroView property and add the ABCIntroViewDelegate. 创建ABCIntroView属性以及添加ABCIntroViewDelegate代理。

  3. Add the following line of code to your ViewDidLoad: 然后将以下代码添加到你的ViewDidLoad:方法中。

    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
if (![defaults objectForKey:@"intro_screen_viewed"]) {
self.introView = [[ABCIntroView alloc] initWithFrame:self.view.frame];
self.introView.delegate = self;
self.introView.backgroundColor = [UIColor greenColor];
[self.view addSubview:self.introView];
}
  1. Add the ABCIntroView Delegate Method: 添加ABCIntroView代理方法
#pragma mark - ABCIntroViewDelegate Methods

-(void)onDoneButtonPressed{
// Uncomment so that the IntroView does not show after the user clicks "DONE"
// NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]
// [defaults setObject:@"YES"forKey:@"intro_screen_viewed"];
// [defaults synchronize];
[UIView animateWithDuration:1.0 delay:0 options:UIViewAnimationOptionCurveEaseInOut animations:^{
self.introView.alpha = 0;
} completion:^(BOOL finished) {
[self.introView removeFromSuperview];
}];
}

If you have any questions about the project, please don't hesitate to ask.

如果有任何关于项目的疑问,不吝赐教。

Enjoy! :)

Adam

[翻译] ABCIntroView的更多相关文章

  1. 《Django By Example》第五章 中文 翻译 (个人学习,渣翻)

    书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者@ucag注:大家好,我是新来的翻译, ...

  2. 《Django By Example》第四章 中文 翻译 (个人学习,渣翻)

    书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:祝大家新年快乐,这次带来<D ...

  3. [翻译]开发文档:android Bitmap的高效使用

    内容概述 本文内容来自开发文档"Traning > Displaying Bitmaps Efficiently",包括大尺寸Bitmap的高效加载,图片的异步加载和数据缓存 ...

  4. 【探索】机器指令翻译成 JavaScript

    前言 前些时候研究脚本混淆时,打算先学一些「程序流程」相关的概念.为了不因太枯燥而放弃,决定想一个有趣的案例,可以边探索边学. 于是想了一个话题:尝试将机器指令 1:1 翻译 成 JavaScript ...

  5. 《Django By Example》第三章 中文 翻译 (个人学习,渣翻)

    书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:第三章滚烫出炉,大家请不要吐槽文中 ...

  6. 《Django By Example》第二章 中文 翻译 (个人学习,渣翻)

    书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:翻译完第一章后,发现翻译第二章的速 ...

  7. 《Django By Example》第一章 中文 翻译 (个人学习,渣翻)

    书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:本人目前在杭州某家互联网公司工作, ...

  8. 【翻译】Awesome R资源大全中文版来了,全球最火的R工具包一网打尽,超过300+工具,还在等什么?

    0.前言 虽然很早就知道R被微软收购,也很早知道R在统计分析处理方面很强大,开始一直没有行动过...直到 直到12月初在微软技术大会,看到我软的工程师演示R的使用,我就震惊了,然后最近在网上到处了解和 ...

  9. ASP.NET MVC with Entity Framework and CSS一书翻译系列文章之第一章:创建基本的MVC Web站点

    在这一章中,我们将学习如何使用基架快速搭建和运行一个简单的Microsoft ASP.NET MVC Web站点.在我们马上投入学习和编码之前,我们首先了解一些有关ASP.NET MVC和Entity ...

随机推荐

  1. spring使用@Value注解读取.properties文件时出现中文乱码问题的解决

    解决办法 在spring中我们常常使用.properties对一些属性进行一个提前配置, spring 在读取*.properties文件时, 默认使用的是asci码, 这时 我们需要对其编码进行转换 ...

  2. JavaScript设计模式-1.函数

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  3. 使用wireshark出现Couldn't run /usr/bin/dumpcap in child process: Permission denied解决办法

    sudo apt-get install libcap2-bin wireshark sudo chgrp myusername /usr/bin/dumpcap # myusername是你使用wi ...

  4. sql中字符串连接

    有时候我们需要将由不同栏位获得的资料串连在一起,每一种数据库都提供一定的方法来达到这个目的,比如: MySQL: CONCAT() Oracle: CONCAT(), || SQL Server: + ...

  5. FOCUS数据管理:数据字典与多维模型

    这是我从工厂出来的第五个年头,也是我第一次主动写年终总结: 回想这一年来一点成就都没有,想想都有点后怕:而且每天还是干着同样的事情,容易被新手代替,由于我比较厌烦每天重复的干同样的活,所以我开始思考是 ...

  6. SSH安全登陆原理:密码登陆与公钥登陆

      SSH全称(Secure SHell)是一种以安全性闻名的应用层网络通信协议,用于计算机间的安全通信,是目前比较成熟的远程登陆解决方案. 它提供两种方法登陆: 1.密码登陆 2.公钥登陆   密码 ...

  7. 使用 Angular 和 RxJS 实现的无限滚动加载

    无限滚动加载应该是怎样的? 无限滚动加载列表在用户将页面滚动到指定位置后会异步加载数据.这是避免寻主动加载(每次都需要用户去点击)的好方法,而且它能真正保持应用的性能.同时它还是降低带宽和增强用户体验 ...

  8. emit 方法表翻译

      Name Description Add Adds two values and pushes the result onto the evaluation stack.添加两个值并将结果推送到评 ...

  9. 根据Time Protocol从NIST Internet Time Servers获取准确时间

    Time Protocol(RFC-868)是一种非常简单的应用层协议:它返回一个32位的二进制数字,这个数字描述了从1900年1月1日0时0分0秒到现在的秒数,服务器在TCP的37号端口监听时间协议 ...

  10. 阿里java面试题,你能答对多少?

    答对以下这些面试题,可以淘汰掉 80 % 的求职竞争者. 1.hashcode相等两个类一定相等吗?equals呢?相反呢? 2.介绍一下集合框架? 3.hashmap hastable 底层实现什么 ...