摘要:
下面的if判断,是因为锁屏显示歌词和歌手图片是在iOS5以后才支持的。iOS5之前的系统不支持锁屏显示东西。 阅读全文
摘要:
1:cmd+l 锁屏幕iOS本地通知在程序运行时不会推动消息,只有在程序进入后台时才会提醒。- (IBAction)addLocalNote { // 1.创建通知 UILocalNotification *localNote = [[UILocalNotification alloc]... 阅读全文
摘要:
http://bbs.csdn.net/topics/390814472打印的日志如下:(notloaded)解决办法:还原模拟器就ok了,操作步骤:iOSSimulator>ResetContentandSettings...再运行就OK了 阅读全文
摘要:
block的内存泄漏(当前控制器是MJViewController)1.1下面黄线警告的那句代码是有内存泄漏的,这是block引起的。1.2 解决办法 阅读全文
摘要:
错误1:1.1这种错误都是storyboard有问题解决:当前storyboard的Custom Class是MJViewController,代码中MJViewController继承自UITableViewController。而storyboard目前提供的是UIViewController,... 阅读全文
摘要:
使用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... 阅读全文
摘要:
SQLite的基本使用//// IWViewController.m// 01-SQLite的基本使用//// Created by apple on 14-5-22.// Copyright (c) 2014年 itcast. All rights reserved.//#import "... 阅读全文
摘要:
1 通过nib方式 // bundle:nil参数传nil,指的是从mainbundle中加载,mainbundle中包含项目中所有的资源 MJThreeViewController *three = [[MJThreeViewController alloc] initWithNibN... 阅读全文
摘要:
注意事项:特殊高度,UITabBar的高度是49,UINavigationBar的高度是44UITabBar的内部结构右边红色的view覆盖在左边的蓝色view上,最终效果图是图2图1:图2:1 UITabBarController的使用步骤初始化UITabBarController设置UIWind... 阅读全文
摘要:
0 :状态栏的高度是20,导航栏的高度是44,在iOS7下状态栏的颜色会被导航栏的颜色同化。图片中紫色的是状态栏,绿色的是导航栏1:UINavigationController的使用步骤初始化UINavigationController设置UIWindow的rootViewController为UI... 阅读全文