摘要: 围绕着某一块特定区域显示(箭头指定那块特定区域) - (void)presentPopoverFromRect:(CGRect)rect inView:(UIView *)view permittedArrowDirections:(UIPopoverArrowDirection)arrowDire 阅读全文
posted @ 2016-04-29 18:59 suifenglangzi 阅读(113) 评论(0) 推荐(0) 编辑
摘要: - (NSArray *)wineArray { if (!_wineArray) { NSArray *dictArray = [NSArray arrayWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"wine.plist" 阅读全文
posted @ 2016-04-29 15:22 suifenglangzi 阅读(148) 评论(0) 推荐(0) 编辑
摘要: 1. 导入Social.framework2. 判断服务是否可用 [SLComposeViewController isAvailableForServiceType:SLServiceTypeSinaWeibo];3. 弹出分享内容输入界面 SLComposeViewController *cc 阅读全文
posted @ 2016-04-25 12:13 suifenglangzi 阅读(212) 评论(0) 推荐(0) 编辑
摘要: 使用不透明视图。不透明的视图可以极大地提高渲染的速度。因此如非必要,可以将table cell及其子视图的opaque属性设为YES(默认值)。其中的特例包括背景色,它的alpha值应该为1(例如不要使用clearColor);图像的alpha值也应该为1,或者在画图时设为不透明。 不要重复创建不必 阅读全文
posted @ 2016-04-25 09:44 suifenglangzi 阅读(824) 评论(0) 推荐(0) 编辑
摘要: 1,在适当的时候,调用此方法跳转到对应的设置界面[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"跳转不同界面对应的URLString"]];详见如下: import UIKit class ViewControlle 阅读全文
posted @ 2016-04-23 19:18 suifenglangzi 阅读(191) 评论(0) 推荐(0) 编辑
摘要: import UIKit import StoreKit class ViewController: UITableViewController { // 数据源, 用于显示可以被销售的商品列表 var products: [SKProduct] = [SKProduct]() { didSet { 阅读全文
posted @ 2016-04-21 16:27 suifenglangzi 阅读(446) 评论(0) 推荐(0) 编辑
摘要: import UIKit import StoreKit class ViewController: UITableViewController { var products: [SKProduct] = [SKProduct]() { didSet { tableView.reloadData() 阅读全文
posted @ 2016-04-21 15:58 suifenglangzi 阅读(276) 评论(0) 推荐(0) 编辑
摘要: 1. 下载框架 2. 导入框架到项目 3. 问题解决 问题1: Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_CLLocation", referenced from: 导致原因:没有导入第三方框架要依赖的系统框架 解决方案:比这 阅读全文
posted @ 2016-04-19 19:14 suifenglangzi 阅读(199) 评论(0) 推荐(0) 编辑
摘要: // MARK:- 事件监听的函数 extension HomeViewController { @objc private func titleBtnClick(titleBtn : TitleButton) { // 1.改变按钮的状态 titleBtn.selected = !titleBtn 阅读全文
posted @ 2016-04-19 18:42 suifenglangzi 阅读(150) 评论(0) 推荐(0) 编辑
摘要: import UIKit import MapKit class ViewController: UIViewController { @IBOutlet weak var mapView: MKMapView! lazy var locationM: CLLocationManager = { l 阅读全文
posted @ 2016-04-17 17:37 suifenglangzi 阅读(352) 评论(0) 推荐(0) 编辑