IOS
追梦浮云
这个作者很懒,什么都没留下…
展开
-
Xcode6.2如何关闭特定文件的ARC功能
在创建项目工程时,ARC(Automatic Reference Counting)是默认开启的,虽然ARC很好用,但有时不得不关闭。比如Xcode中经常需要导入一些外来的代码文件,如果导入的文件没有使用ARC机制而当前项目使用了ARC,Xcode会给出警告或者错误信息,这时就需要关闭或开启ARC功能了。可采取下面的方式彻底关闭整个工程的ARC点击项目导航文件--> 选中Targe原创 2015-04-21 19:04:55 · 1847 阅读 · 0 评论 -
UIApplication 状态及状态切换
摘自:IOS编程(第4版)原创 2015-08-24 10:33:47 · 499 阅读 · 0 评论 -
UIView frame, bounds and center
http://stackoverflow.com/questions/5361369/uiview-frame-bounds-and-centerTo help me remember frame, I think of a picture frame on a wall. Just like a picture can be moved anywhere on the wal转载 2015-07-22 10:31:18 · 577 阅读 · 0 评论 -
UIRefreshControl 实现UITableView的下拉刷新
本文通过使用UITableView自带的控件UIRefreshControl实现下拉刷新。用UIRefeshControl控件实现下拉刷新,可以实现一定功能的自定义下拉菜单,比如要显示的文字、颜色。但这种方法简单,高效,容易理解,毕竟是apple自带的下拉刷新空间,UITableViewController:首先xcode创建一个UITableViewController原创 2015-08-03 19:36:42 · 2302 阅读 · 0 评论 -
block 块实现传值
使用块(block)传值比较简单,并且用块写出来的代码更为整洁。代码模拟:声明文件:#import typedef void (^GBCompletionHandler)(NSData* data, NSError *error);@interface GBUpload : NSObject/** * upload data to some where * * @原创 2015-07-23 20:05:33 · 900 阅读 · 0 评论 -
Xcode编译后的文件路径
编译后的文件路径:/Users/用户名/Library/Developer/Xcode/DerivedData/工程名-sdsdfsfdsfdsdfsf/Build/Products文件下面有Debug-iphonesimulator,Release-iphonesimulator可以通过Xcode直接进入:Xcode -> Preferences -> Locations原创 2016-03-30 10:21:16 · 6502 阅读 · 0 评论 -
Objective-C:单例模式
objecitive C的单例模式:#import @class SingleInstance;static SingleInstance *instance = nil;@interface SingleInstance : NSObject+ (instancetype)sharedInstance;@end@interface SingleInstance ()原创 2016-03-23 21:31:36 · 521 阅读 · 0 评论 -
iOS 隐藏backBarButtonItem
[self.navigationItem setHidesBackButton:YES];原创 2016-04-07 10:54:45 · 1224 阅读 · 0 评论