摘要: oc总结1、id与instancetypeid万能指针,指向所有oc对象,可以作为方法返回值类型、函数参数使用。instancetype只能使用在方法返回值类型处,说明返回值的类型为当前类的类型。2、变量的作用域publicprivate,私有的,只能在当前类中直接访问,在实现中声明的成员变量默认就... 阅读全文
posted @ 2015-11-15 16:06 Darren-chen 阅读(219) 评论(0) 推荐(0)
摘要: 1.设置custom长按时不会变成灰色2.按钮的background image和image如果设置按钮的文字为[btn setTitle:@"按钮" forState:UIControlStateNormal];使用background image不会覆盖文字,使用image会覆盖文字4.logi... 阅读全文
posted @ 2015-11-15 16:03 Darren-chen 阅读(203) 评论(0) 推荐(0)
摘要: 由于系统的UIBarButtonItem *rightButton和UIBarButtonItem *rightButton的位置已经固定,但有时我们又想改变他的位置,可以这么做 // 设置右边的按钮 UIButton *rightBtn = [[UIButton alloc] initWithFr... 阅读全文
posted @ 2015-11-15 15:12 Darren-chen 阅读(658) 评论(0) 推荐(0)