iOS
博然公寓
这个作者很懒,什么都没留下…
展开
-
iOS 抖动动画
// 抖动动画 CABasicAnimation *shakeAnimation = [CABasicAnimation animationWithKeyPath:@”transform.translation.y”]; shakeAnimation.duration = 0.25f; shakeAnimation.fromValue = [NSNumber numbe原创 2016-01-23 15:14:50 · 353 阅读 · 0 评论 -
iOS 获取手机型号
// 获取手机型号 (NSString*)deviceVersion {// 需要#import "sys/utsname.h"struct utsname systemInfo;uname(&systemInfo);NSString *deviceString = [NSStringstringWithCString:systemInfo.machineencoding:NSUTF8StringE原创 2016-01-23 15:17:06 · 237 阅读 · 0 评论 -
tableview自定义空间代理方法
自定义cell.h文件@class ProductCollectionViewCell; @protocol ProductCountDelegate <NSObject> (void)collectionCell:(ProductCollectionViewCell )cell btn:(UIButton)btn countLable:(UILabel *)countLable; @end@pr原创 2016-01-23 15:19:17 · 274 阅读 · 0 评论 -
iOS 系统消息通知
一、键盘 1、UIKeyboardWillShowNotification-将要弹出键盘 2、UIKeyboardDidShowNotification-显示键盘 3、UIKeyboardWillHideNotification-将要隐藏键盘 4、UIKeyboardDidHideNotification-键盘已经隐藏 5、UIKeyboardWillChangeFrameNotification-转载 2016-01-23 15:30:03 · 1290 阅读 · 0 评论 -
iOS 显示%
显示98%。。。显示百分号% progressValue是一个浮点数。 valueLabel.text = [NSString stringWithFormat:@”%.0f%%”,progressValue]; int Value = 6;NSString *string = [NSString stringWithFormat:@"%d%@",Value,@"%"];NSLog(@"s原创 2016-01-23 15:51:10 · 1010 阅读 · 1 评论 -
iOS UIWebView 代理方法
//初始化webview myWebView=[[UIWebView alloc]initWithFrame:CGRectMake(0, 22, [UIScreen mainScreen].bounds.size.width, [UIScreen mainScreen].bounds.size.height-22)]; myWebView.delegate=self;原创 2016-01-25 15:23:58 · 5512 阅读 · 0 评论