上一页 1 2 3 4 5 6 7 ··· 10 下一页
摘要: http://technet.microsoft.com/zh-cn/library/tc5zwdf7%28v=vs.80%29 阅读全文
posted @ 2013-05-26 11:31 Peter_youny 阅读(428) 评论(5) 推荐(0) 编辑
摘要: 拷贝有两种:深拷贝,浅拷贝当出现类的等号赋值时,会调用拷贝函数在未定义显示拷贝构造函数的情况下,系统会调用默认的拷贝函数——即浅拷贝,它能够完成成员的一一复制。当数据成员中没有指针时,浅拷贝是可行的。但当数据成员中有指针时,如果采用简单的浅拷贝,则两类中的两个指针将指向同一个地址,当对象快结束时,会调用两次析构函数,而导致指针悬挂现象。所以,这时,必须采用深拷贝。深拷贝与浅拷贝的区别就在于深拷贝会在堆内存中另外申请空间来储存数据,从而也就解决了指针悬挂的问题。简而言之,当数据成员中有指针时,必须要用深拷贝。 阅读全文
posted @ 2013-05-03 17:51 Peter_youny 阅读(169) 评论(0) 推荐(0) 编辑
摘要: 参考文档:http://blog.csdn.net/dongstone/article/details/7428157这里面需要的是使用了静态文件Property List.plist需要对其进行初始化。.h#import <UIKit/UIKit.h>@interface YYWViewController : UIViewController<UITableViewDelegate,UITableViewDataSource>@property(nonatomic,strong) NSDictionary *listData;@property(nonatomic, 阅读全文
posted @ 2013-05-03 16:42 Peter_youny 阅读(1442) 评论(0) 推荐(0) 编辑
摘要: html<html><head> <meta charset="utf-8"> <meta name="handheldfriendly" content="true" /> <meta http-equiv="Pragma" content="no-cache" /> <!--兼容HTTP1.0--> <meta http-equiv="Cache-Control" content="n 阅读全文
posted @ 2013-04-25 11:50 Peter_youny 阅读(239) 评论(0) 推荐(0) 编辑
摘要: <script> window.onscroll = function () { var obj = document.getElementById("thirdnav"); var topa = obj.offsetTop; var top = document.documentElement.scrollTop; document.getElementById("showHeight").innerHTML = topa - top; } </script> 阅读全文
posted @ 2013-04-24 17:39 Peter_youny 阅读(1262) 评论(0) 推荐(0) 编辑
摘要: http://v.youku.com/v_playlist/f2416830o1p0.html 阅读全文
posted @ 2013-04-24 16:30 Peter_youny 阅读(88) 评论(0) 推荐(0) 编辑
摘要: .h#import <UIKit/UIKit.h>@interface YYWViewController : UIViewController<UITableViewDelegate,UITableViewDataSource>@property(nonatomic,strong) NSArray *listData;@end.m#import "YYWViewController.h"@interface YYWViewController ()@end@implementation YYWViewController- (void)viewDi 阅读全文
posted @ 2013-04-23 16:48 Peter_youny 阅读(185) 评论(0) 推荐(0) 编辑
摘要: .h#import <UIKit/UIKit.h>@interface YYWViewController : UIViewController<UIPickerViewDelegate, UIPickerViewDataSource> @property (retain, nonatomic) IBOutlet UIPickerView *pickerView;@property(retain,nonatomic)IBOutlet UILabel *selectLabel;@property (strong, nonatomic) NSArray *pickerDat 阅读全文
posted @ 2013-04-23 11:41 Peter_youny 阅读(1565) 评论(0) 推荐(0) 编辑
摘要: NSMutableArray *sortedArray; sortedArray = [array sortedArrayUsingComparator:^NSComparisonResult(id a, id b) { double first = [(People*)a getValueA]; double second = [(People*)b getValueA]; return second-first; }];更多:http://iphone.xiaoxiaostudio.net/2012/11/20/%E5%A6%82%E4%BD%95%E7%BB%99nsm... 阅读全文
posted @ 2013-04-05 20:24 Peter_youny 阅读(115) 评论(0) 推荐(0) 编辑
摘要: 参考:http://www.cnblogs.com/minglz/archive/2012/11/27/2788343.html(1)@interface YYWViewController : UIViewController <UIActionSheetDelegate>(2)- (IBAction)btnAlert:(id)sender { UIActionSheet * actionSheet = [[UIActionSheetalloc] initWithTitle:@"Are you sure?" delegate:... 阅读全文
posted @ 2013-03-26 10:47 Peter_youny 阅读(194) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 ··· 10 下一页