[翻译] ABCIntroView
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:
你需要遵循以下几步来使用它:
- Add the follwing files found in the CLASSES folder to your project: 将以下几个文件拖到你的项目当中:
*ABCIntroView.h
*ABCIntroView.m
Import the ABCIntoView file to your RootViewController. 将ABCIntoView文件引入到你的RootViewController当中。
Create an ABCIntroView property and add the ABCIntroViewDelegate. 创建ABCIntroView属性以及添加ABCIntroViewDelegate代理。
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];
}
- 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的更多相关文章
- 《Django By Example》第五章 中文 翻译 (个人学习,渣翻)
书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者@ucag注:大家好,我是新来的翻译, ...
- 《Django By Example》第四章 中文 翻译 (个人学习,渣翻)
书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:祝大家新年快乐,这次带来<D ...
- [翻译]开发文档:android Bitmap的高效使用
内容概述 本文内容来自开发文档"Traning > Displaying Bitmaps Efficiently",包括大尺寸Bitmap的高效加载,图片的异步加载和数据缓存 ...
- 【探索】机器指令翻译成 JavaScript
前言 前些时候研究脚本混淆时,打算先学一些「程序流程」相关的概念.为了不因太枯燥而放弃,决定想一个有趣的案例,可以边探索边学. 于是想了一个话题:尝试将机器指令 1:1 翻译 成 JavaScript ...
- 《Django By Example》第三章 中文 翻译 (个人学习,渣翻)
书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:第三章滚烫出炉,大家请不要吐槽文中 ...
- 《Django By Example》第二章 中文 翻译 (个人学习,渣翻)
书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:翻译完第一章后,发现翻译第二章的速 ...
- 《Django By Example》第一章 中文 翻译 (个人学习,渣翻)
书籍出处:https://www.packtpub.com/web-development/django-example 原作者:Antonio Melé (译者注:本人目前在杭州某家互联网公司工作, ...
- 【翻译】Awesome R资源大全中文版来了,全球最火的R工具包一网打尽,超过300+工具,还在等什么?
0.前言 虽然很早就知道R被微软收购,也很早知道R在统计分析处理方面很强大,开始一直没有行动过...直到 直到12月初在微软技术大会,看到我软的工程师演示R的使用,我就震惊了,然后最近在网上到处了解和 ...
- ASP.NET MVC with Entity Framework and CSS一书翻译系列文章之第一章:创建基本的MVC Web站点
在这一章中,我们将学习如何使用基架快速搭建和运行一个简单的Microsoft ASP.NET MVC Web站点.在我们马上投入学习和编码之前,我们首先了解一些有关ASP.NET MVC和Entity ...
随机推荐
- 第十篇----------javascript函数的三种定义方式及区别
javascript定义函数有3种方式: //3种函数定义方式,前两种常用 /** * 1,function 语句式 * 形式:句子 * 名称:有名 * 性质:静态 * 解析时机:优先解析 * 作用域 ...
- Struts2方法调用的三种方式(有新的!调用方法的说明)
在Struts2中方法调用概括起来主要有三种形式 第一种方式:指定method属性 <action name="heroAction" class="com.ABC ...
- JSTL之<c:set>的各种用法
<c:set>标签用于设置变量值和对象属性 语法格式 <span style="font-size:18px;"><c:set var="& ...
- java线程状态 以及 sheep()、wait()、yield() 区别
前言 最近看到很多人都在讨论多线程的问题,于是写出了这篇博客,希望可以帮到正在学习和使用这块的朋友们,首先我们先看看两个图(两个图都来自其他码农的分享) 这两个图是一样的逻辑,这里一起罗列出来,下 ...
- c#和java中封装字段的不同
c#: private String name; public String Name { get { return name; } set { name = value; } } .csharpco ...
- Universal App图片文件和图片byte[]信息转换为bitmap
1. 打开图片文件并转换为BitmapImage类 首先要做的自然是打开一个图片文件了,可以使用FileOpenPicker来手动选择图片,总之能拿到一个StorageFile都行. //打开图片选择 ...
- c#项目代码风格要求
代码风格没有正确与否,重要的是整齐划一,这是我拟的一份<.Net 项目代码风格要求>,供大家参考. 1. C# 代码风格要求 1.1注释 类型.属性.事件.方法.方法参数,根据需要添加注释 ...
- DES c#加密后java解密
public static String byteArr2HexStr(byte[] bytIn) { StringBuilder builder = new StringBuilder(); for ...
- JavaScript内置对象与原生对象【转】
原文:https://segmentfault.com/a/1190000002634958 内置对象与原生对象 内置(Build-in)对象与原生(Naitve)对象的区别在于:前者总是在引擎初始化 ...
- mongdb启动报错
2018-08-19T12:25:31.707+0800 I CONTROL [main] Automatically disabling TLS 1.0, to force-enable TLS 1 ...