iOS 键盘视图 CLKeyboardOffsetView
- 授权协议: MIT
- 开发语言: Objective-C
- 操作系统: iOS
- 软件首页: https://github.com/changelee82/CLKeyboardOffsetView
- 软件文档: https://github.com/changelee82/CLKeyboardOffsetView
软件介绍
使用方法:
#import "UIView+CLKeyboardOffsetView.h"
- (void)viewDidAppear:(BOOL)animated
{
[super viewDidAppear:animated];
// 打开键盘补偿视图
[self.view openKeyboardOffsetView];
self.view.keyboardGap = 10; // 如果需要自定义键盘与第一响应者之间的间隙,则设置此属性,默认为5
}
- (void)viewDidDisappear:(BOOL)animated
{
[super viewDidDisappear:animated];
// 关闭键盘补偿视图
[self.view closeKeyboardOffsetView];
}
如果需要自定义视图向上移动的高度,则使用代理
<CLKeyboardOffsetViewDelegate>
self.view.keyboardOffsetViewDelegate = self;
并添加代理方法
/**
* 弹出键盘时,自定义视图向上移动的高度
*
* @param firstResponder 第一响应者
* @param keyboardHeight 当前弹出键盘的高度
* @param offsetHeight 默认偏移高度
*
* @return 视图向上移动的高度
*/
- (CGFloat)offsetViewHeightWithFirstResponder:(UIView *)firstResponder
keyboardHeight:(CGFloat)keyboardHeight
offsetHeight:(CGFloat)offsetHeight
{
if ([firstResponder isEqual:_testTextField])
{
return keyboardHeight;
}
return offsetHeight;
}
Lighttpd源码分析
高群凯 / 机械工业出版社 / 2010-3 / 59.00元
本书主要针对lighttpd源码进行了深度剖析。主要内容包括:lighttpd介绍与分析准备工作、lighttpd网络服务主模型、lighttpd数据结构、伸展树、日志系统、文件状态缓存器、配置信息加载、i/o多路复用技术模型、插件链、网络请求服务响应流程、请求响应数据快速传输方式,以及基本插件模块。本书针对的lighttpd项目版本为稳定版本1.4.20。 本书适合使用lighttpd的人......一起来看看 《Lighttpd源码分析》 这本书的介绍吧!
