上一页 1 ··· 5 6 7 8 9 10 11 下一页
摘要: 自定义的UITableViewCell,使用xib方式创建,想要其中的UILabel换行显示:计算Label的高度,让其自动换行,总是没有效果。我猜测原因可能在于使用了autolayout布局。只要将Label的宽度固定,即添加宽度约束,UILabel就可以自动换行了。记录一下,避免在此遇到问题忘了... 阅读全文
posted @ 2016-01-26 15:09 ha_cjy 阅读(1386) 评论(0) 推荐(0) 编辑
摘要: /* * 设置子项cell **/- (UITableViewCell *)getChildCell:(UITableView *)tableView and:(NSIndexPath *)indexPath { CourseWareModel * childModel = [self isC... 阅读全文
posted @ 2016-01-26 15:04 ha_cjy 阅读(2361) 评论(0) 推荐(0) 编辑
摘要: /** * 获取当前屏幕截图,包含状态栏 */ public static Bitmap snapShotWithStatusBar(Activity activity){ View view = activity.getWindow().getDecorView... 阅读全文
posted @ 2016-01-19 17:15 ha_cjy 阅读(311) 评论(0) 推荐(0) 编辑
摘要: 由于今天在NSDictionary初始化的时候出现Crash异常,故记录一下,避免下次再犯。在Objective-C中,NSDictionary初始化的方法有很多种方法1:[NSDictionary dictionaryWithObjectsAndKeys:, nil]方法2:NSDictionar... 阅读全文
posted @ 2016-01-19 16:09 ha_cjy 阅读(1409) 评论(0) 推荐(0) 编辑
摘要: + (NSString *) stringByReplaceUnicode:(NSString *)string{ NSMutableString *convertedString = [string mutableCopy]; [convertedString replaceOccur... 阅读全文
posted @ 2016-01-19 15:02 ha_cjy 阅读(1521) 评论(0) 推荐(0) 编辑
摘要: #pragma mark 去除多余的线-(void) clearExtrLine{ UIView *view = [[UIView alloc] init]; view.backgroundColor = [UIColor clearColor]; [tableView setTa... 阅读全文
posted @ 2016-01-19 15:01 ha_cjy 阅读(643) 评论(0) 推荐(0) 编辑
摘要: #pragma -mark 以下2个方法,解决分割线不满屏问题-(void)viewDidLayoutSubviews { if ([tableView respondsToSelector:@selector(setSeparatorInset:)]) { [table... 阅读全文
posted @ 2016-01-19 15:00 ha_cjy 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 场景在 App 中使用UIWebView加载网页, 与原生的 UI 显示在一起,一般情况下,webView 的 内容一页是肯定不够的,换句话说,webView 的高度是不定的,那如果原生的 UI是一个 ScrollView,高度也是不定的,那放在一起的话就会有两个 ScrollView 分别滚动,而... 阅读全文
posted @ 2016-01-19 11:20 ha_cjy 阅读(786) 评论(0) 推荐(0) 编辑
摘要: 运行支付宝官方demo进行支付测试,会出现6002-网络连接错误,是因为以iOS9 SDK编译的工程会默认以SSL安全协议进行网络传输,即HTTPS,如果依然使用HTTP协议请求网络会报系统异常并中断请求。同样的,如果你的应用使用了如SSO授权登录或跳转分享功能,在iOS9下就需要增加一个可跳转的白... 阅读全文
posted @ 2016-01-18 11:16 ha_cjy 阅读(2888) 评论(1) 推荐(0) 编辑
摘要: 方法:public Dialog createDialog(Context context, View view) { Dialog mSelectPhotoDialog = null; mSelectPhotoDialog = new Dialog(context, R... 阅读全文
posted @ 2016-01-13 09:52 ha_cjy 阅读(949) 评论(0) 推荐(0) 编辑
上一页 1 ··· 5 6 7 8 9 10 11 下一页