摘要: UIWindow *window = [[[UIApplication sharedApplication] windows] lastObject]; UIView * keyview=[[window subviews] lastObject]; UIView * view=[[UIView a 阅读全文
posted @ 2016-05-18 14:47 frounk 阅读(710) 评论(0) 推荐(0) 编辑
摘要: 如何通过代码来修改iphone联系人头像 使用如下代码: UIImage *image=[UIImage imageNamed:@"star_full.png"]; NSData *data=UIImagePNGRepresentation(image); ABPersonRemoveImageDa 阅读全文
posted @ 2016-05-17 15:20 frounk 阅读(444) 评论(0) 推荐(0) 编辑
摘要: //清除本地缓存 -(void)clearCache{ dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT,0) , ^{ NSString *cachPath = [NSSearchPathFo... 阅读全文
posted @ 2016-05-10 10:23 frounk 阅读(183) 评论(0) 推荐(0) 编辑
摘要: @property (nonatomic, strong) UISearchController* searchController; self.searchController = [[UISearchController alloc] initWithSearchResultsController:nil]; self.searchController.delegate=... 阅读全文
posted @ 2016-05-02 11:49 frounk 阅读(416) 评论(0) 推荐(0) 编辑
摘要: [[UIDevice currentDevice] setProximityMonitoringEnabled:NO]; //建议在播放之前设置yes,播放结束设置NO,这个功能是 //添加监听 self @selector(sensorStateChange:) @"UIDeviceProximi 阅读全文
posted @ 2016-04-30 16:47 frounk 阅读(665) 评论(0) 推荐(0) 编辑
摘要: - (void)setExtraCellLineHidden: (UITableView *)tableView { UIView *view = [UIView new]; view.backgroundColor = [UIColor clearColor]; [tableView setTableFooterView:view]; } //调用 [self... 阅读全文
posted @ 2016-04-30 13:38 frounk 阅读(283) 评论(0) 推荐(0) 编辑
摘要: 1 self.window.rootViewController.view.alpha = 0; 2 UIImageView *splashImageView = [[UIImageView alloc]initWithImage:[UIImage imageNamed:@"Defauit_o"]]; 3 splashImageView.frame=CGRectMake(0,... 阅读全文
posted @ 2016-04-27 17:03 frounk 阅读(259) 评论(0) 推荐(0) 编辑
摘要: 实现右侧的小灰色箭头 只要将cell的accessoryType属性设置为 UITableViewCellAccessoryDisclosureIndicator就可以了。 代码为:cell.accessoryType=UITableViewCellAccessoryDisclosureIndica 阅读全文
posted @ 2016-04-20 15:54 frounk 阅读(259) 评论(0) 推荐(0) 编辑
摘要: UITableView的scrollToRowAtIndexPath:atScrollPosition:animated的崩溃 UITableView的scrollToRowAtIndexPath:atScrollPosition:animated的崩溃 [摘要:reason: '-[UITable 阅读全文
posted @ 2016-04-09 17:42 frounk 阅读(5475) 评论(0) 推荐(0) 编辑
摘要: 手写代码自动实现自动布局,即Auto Layout的使用,有需要的朋友可以参考下。这里要注意几点: 对子视图的约束,若是基于父视图,要通过父视图去添加约束。 对子视图进行自动布局调整,首先对UIView的一个属性设置,这是因为如果我们用Interface Builder,勾选Ues Autolayo 阅读全文
posted @ 2016-04-01 12:10 frounk 阅读(311) 评论(0) 推荐(0) 编辑