- 博客(12)
- 收藏
- 关注
转载 UITableView 总结
UITableView 总结UITableView是UIScrollView的子类,因此它可以自动响应滚动事件(一般为上下滚动)。它内部包含0到多个UITableViewCell对象,每个table cell展示各自的内容。当新cell需要被显示时,就会调用tableView:cellForRowAtIndexPath:方法来获取或创建一个cell;而不可视时,它又会被
2016-03-04 17:20:47 326
原创 JSONModel的使用
JSONModel, Mantle这两个开源库都是用来进行封装JSON->Model的, 想想看, 直接向服务器发起一个请求,然后回来后,就是一个Model, 直接使用, 这是一个多么美好的事情。 感谢GitHub的开源精神。那我们开始吧。 先说说这两个的差别。这两个使用的方法其实都差不多, 详细的使用方法请直接GitHub上找, 还是比较简单地。 就我个人来说JSONMo
2016-03-03 11:16:08 317
原创 iOS json解析遇到@"";@"<null>";null 处理
if(![strisEqualToString:@""]&&![strisEqual:[NSNullnull]]&&![strisEqualToString:@""]){ //需要的内容}
2015-12-17 11:19:30 360
原创 iOS 模态到一个有自定制Tabar的页面,tabbar消失的问题
问题的原因不难,问题在于怎么解决,解决方法如下:- (void)button2{ One * vc1 = [[Onealloc] init]; vc1.view.backgroundColor = [UIColorcyanColor]; Two * vc2 = [[Twoalloc] init]; vc2.vi
2015-12-14 17:44:00 1540
原创 iOS 设置视图半透明而子控件不透明
UIColor *color = [UIColor blackColor];bgView.backgroundColor = [color colorWithAlphaComponent:0.5];
2015-12-14 00:09:03 649
原创 iOS 简单实现alertview 定时移除
- (void)viewDidLoad { [superviewDidLoad]; [self showAlert:@"呵呵"]; // Do any additional setup after loading the view, typically from a nib.}//时间- (void)showAlert:(NSS
2015-12-13 16:01:31 485
原创 iOS 错误信息 This application is modifying the autolayout engine from a background thread...
遇到这个错误: This application is modifying the autolayout engine from a background thread, which can lead to engine corruption and weird crashes. This will cause an exception in a future release.我
2015-12-10 17:30:31 375
原创 Xcode7.1 Alcatraz工具的使用
Xcode7.1不能使用Alcatraz解决方案在终端依次输入以下命令rm -rf ~/Library/Application\ Support/Developer/Shared/Xcode/Plug-ins/Alcatraz.xcpluginfind ~/Library/Application\ Support/Developer/Shared/Xcode/Plug-ins -n
2015-12-10 11:14:21 276
原创 iOS CocoaPods 快速导入
想要导入和更新更快,那就使用下面两句吧pod install --verbose --no-repo-updatepod update --verbose --no-repo-update
2015-12-09 17:08:07 297
原创 iOS CoreData 存取数组字典等数据类型
当我们想要在数据库中存入一个数组或者字典的时候,往往有好几种方法,我觉得这种方法比较简单:1.首先建立数据库表,在选择Attribute的Type 的时候选择Transformable2.将请求的NSData数据直接放入数据库中,不需要取解Json3.在取数据的时候,解析数据即可[NSJSONSerializationJSONObjectWithData:user.da
2015-12-09 12:45:32 2646
原创 iOS 简单实现重新获取验证码并倒计时60秒
@implementation ViewController{ UIButton * _receiveCheckNumButton;}- (void)viewDidLoad { [superviewDidLoad]; _receiveCheckNumButton = [[UIButtonalloc] initWithFram
2015-12-08 14:55:21 3726
原创 iOS 简单的实现手机号正误的判断(Warning: Attempt to present... whose view is not in the window hierarchy!
- (void)viewDidLoad { [superviewDidLoad]; /*这里粗略的写了一个按钮, 否则在viewDidLoad中直接运行checkTel方法会报错: Warning: Attempt to present on whose view is not in the window hierarchy!
2015-12-08 14:08:05 400
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人