本文来源于我个人的ARC学习笔记,旨在通过简明扼要的方式总结出iOS开发中ARC(Automatic Reference Counting,自动引用计数)内存管理技术的要点,所以不会涉及全部细节。这篇文章不是一篇标准的ARC使用教程,并假定读者已经对ARC有了一定了解和使用经验。具体而详细的关于AR...
分类:
移动开发 时间:
2015-02-05 18:17:28
阅读次数:
317
因为自己之前在block中需要递归调用自己本身,而没有用weak。导致在[self removeFromSuperview]方法时,CPU使用率一只高达百分之百。。block一直持有self。。。fix:__weak 当前类 *weakSelf = self;[weakSelf 递归调用的方法];这...
分类:
移动开发 时间:
2015-02-05 18:16:35
阅读次数:
163
最近在Linux下编程发现一个诡异的现象,就是在链接一个静态库的时候总是报错,类似下面这样的错误:(.text+0x13): undefined reference to `func'关于undefined reference这样的问题,大家其实经常会遇到。在此,我以详细示例给出常见错误的各种原因以...
分类:
系统相关 时间:
2015-02-05 17:59:35
阅读次数:
276
分辨率、DPI、PPI和屏幕尺寸分辨率DPI/PPI坑爹的屏幕尺寸Reference手机开发中不免会遇到分辨率、DPI、PPI和屏幕尺寸等术语,那就弄弄清楚这些概念的真正含义。分辨率分辨率这个词在很多地方都有,比如相机、视频、扫描仪。这里说的就是显示器的分辨率。显示器是由一个个像素点(pixel)所...
分类:
其他好文 时间:
2015-02-05 00:40:18
阅读次数:
231
这两个条款讲述了何时应该使用引用传递pass by reference,何时应该使用值传递pass by value。...
分类:
编程语言 时间:
2015-02-04 23:25:09
阅读次数:
190
include my own version for your reference. We use this one to zip up photos to download so it works with various unzip programs. It preserves the dire...
分类:
编程语言 时间:
2015-02-04 20:12:25
阅读次数:
218
Android自定义属性,attr format取值类型 1. reference:参考某一资源ID。 (1)属性定义: <declare-styleable name = "名称"> <attr name = "background" format = "reference" /> </declare-styleable> (2)属...
分类:
其他好文 时间:
2015-02-04 14:52:28
阅读次数:
197
//委托的协议定义@protocol UpdateDelegate - (void)update;@end@interface Test : NSObject//委托变量定义@property (nonatomic, weak) id delegate;//blocktypedef void (^U...
分类:
移动开发 时间:
2015-02-04 10:37:53
阅读次数:
186
Shuffling is a procedure used to randomize a deck of playing cards. Because standard shuffling techniques are seen as weak, and in order to avoid "ins...
分类:
系统相关 时间:
2015-02-03 21:12:01
阅读次数:
196
#import "ViewController.h"
#define ImageViewCount 5
@interface ViewController ()
@property (weak, nonatomic) IBOutlet UIScrollView *imageScrollView;
@property (weak, nonatomic) IBOutlet UIPageContro...
分类:
移动开发 时间:
2015-02-03 17:12:25
阅读次数:
210