摘要: 下面的if判断,是因为锁屏显示歌词和歌手图片是在iOS5以后才支持的。iOS5之前的系统不支持锁屏显示东西。 阅读全文
posted @ 2015-02-26 11:03 笑看风雨 阅读(483) 评论(0) 推荐(0) 编辑
摘要: 1:cmd+l 锁屏幕iOS本地通知在程序运行时不会推动消息,只有在程序进入后台时才会提醒。- (IBAction)addLocalNote { // 1.创建通知 UILocalNotification *localNote = [[UILocalNotification alloc]... 阅读全文
posted @ 2015-01-28 17:26 笑看风雨 阅读(287) 评论(0) 推荐(0) 编辑
摘要: http://bbs.csdn.net/topics/390814472打印的日志如下:(notloaded)解决办法:还原模拟器就ok了,操作步骤:iOSSimulator>ResetContentandSettings...再运行就OK了 阅读全文
posted @ 2014-12-27 15:55 笑看风雨 阅读(300) 评论(0) 推荐(0) 编辑
摘要: block的内存泄漏(当前控制器是MJViewController)1.1下面黄线警告的那句代码是有内存泄漏的,这是block引起的。1.2 解决办法 阅读全文
posted @ 2014-12-21 15:57 笑看风雨 阅读(203) 评论(0) 推荐(0) 编辑
摘要: 错误1:1.1这种错误都是storyboard有问题解决:当前storyboard的Custom Class是MJViewController,代码中MJViewController继承自UITableViewController。而storyboard目前提供的是UIViewController,... 阅读全文
posted @ 2014-12-21 15:22 笑看风雨 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 使用autolayout常见错误1:The view hierarchy is not prepared for the constraint: When added to a view, the constraint's items must be descendants of that vie... 阅读全文
posted @ 2014-12-20 09:56 笑看风雨 阅读(6749) 评论(0) 推荐(1) 编辑
摘要: SQLite的基本使用//// IWViewController.m// 01-SQLite的基本使用//// Created by apple on 14-5-22.// Copyright (c) 2014年 itcast. All rights reserved.//#import "... 阅读全文
posted @ 2014-12-18 20:07 笑看风雨 阅读(1050) 评论(0) 推荐(0) 编辑
摘要: 1 通过nib方式 // bundle:nil参数传nil,指的是从mainbundle中加载,mainbundle中包含项目中所有的资源 MJThreeViewController *three = [[MJThreeViewController alloc] initWithNibN... 阅读全文
posted @ 2014-12-05 15:30 笑看风雨 阅读(377) 评论(0) 推荐(0) 编辑
摘要: 注意事项:特殊高度,UITabBar的高度是49,UINavigationBar的高度是44UITabBar的内部结构右边红色的view覆盖在左边的蓝色view上,最终效果图是图2图1:图2:1 UITabBarController的使用步骤初始化UITabBarController设置UIWind... 阅读全文
posted @ 2014-12-04 22:00 笑看风雨 阅读(403) 评论(0) 推荐(0) 编辑
摘要: 0 :状态栏的高度是20,导航栏的高度是44,在iOS7下状态栏的颜色会被导航栏的颜色同化。图片中紫色的是状态栏,绿色的是导航栏1:UINavigationController的使用步骤初始化UINavigationController设置UIWindow的rootViewController为UI... 阅读全文
posted @ 2014-12-04 16:49 笑看风雨 阅读(2663) 评论(0) 推荐(0) 编辑